Josiah P. answered 07/01/19
Musician Experienced in Teaching Drums and Composition
You're absolutely on the right track here. This is a common guiding concept to creating a good balance of tension and release when writing melodies. If all the notes of a melody are the 1, 3, or 5 it will sound bland. If the notes are only the 2, 4, 6, or 7 then the melody will begin to sound disconnected. Use your ears and your own taste as you compose to create a good balance.
Other things also effect tension and release when writing melodies: density or sparsity of notes, intervalic distance - are you moving by steps or leaps?, range - does your melody stay within the same octave or many octaves?, rhythmic variety - how much syncopation is in your melody?, etc. Again, the key is to strike a balance using your own taste. Anything is possible!