In terms of a major scale, I heard that the I and IV chords can be maj7, the V chord is dom7 and the ii, iii, and vi chords can be min7. Would the same logic apply for 9th chords?
Basically, yes. Each is an extension of the process of adding thirds.
With I9, it's a major 9th, IV9 also. V9 is dominant.
vi9 is minor 9th as is ii9. iii9 is also m9, but with the 9th note non-diatonic.
I use maj9 chords for things like this:
- thicker maj7 (i.e. I use it in my cooking the same way I'd use a maj7, but it makes the result feel denser)
- even more elevatorish than maj7
- stronger tonality-setting than maj7
- fast way to Girl from Ipanema, Last Christmas, and similar songs
- the 9th tone is a bit superfluous, so it can be used for rhythmic texturizing voice movement without actually doing anything harmonically substantial (i.e. you can usually add stuff like that for texture or for your own amusement without negotiating with others, and it won't ruin the harmony). Sort of like what you can do by adding a 2nd, but when it's the highest note of the chord, it has more room to move without getting too close to the 3rd.
By stronger tonality-setting I mean, play the chords: B - F (i.e. major chords a tritone apart, so the combination shouldn't make much sense). Then compare with Bmaj7 - Fmaj7. Then compare with Bmaj9 - Fmaj9.
The maj9 version makes me feel the most at rest ("stable" might be the correct theory hygienic word) on both chords, and even the tritone jump doesn't feel as harsh. The feeling of stability might be explained to come from there being more notes of the scale, so it's more explicit and leaves less room for imagination.
How about, now you go and try some uses for the maj9 chord yourself?