Edit - After reading your posts, I see that I provided an explanation of modes that was unnecessary. My bad. I'll just leave it as there was a lot to type. LOL.
In certain types of music, breaking down the song and figuring out what mode to play over certain chords is very common. You'd do this so that you can play/improvise a solo for the song. Jazz, Bossa, etc. would be musical genres where this is common.
In triadic music, which is the more popular type of music most people listen to, once you figure out what key the song is in, you can stick with playing a solo in that key for the entire song in the vast majority of cases. In jazz (bossa, whatever), the key can change multiple times in the song.
Here is a very simple example. Let's say one segment of the song contains the following 3 chords:
Am7 D7 Gmaj7
This is
ii V I ( 2 5 1) in the key of G major. Am7 is the ii chord. D7 is V chord. Gmaj7 is the I chord.
The modes would be:
- Dorian for the ii chord,
- Mixolydian for the V chord
- Ionian for the I chord.
So, breaking down the song into different approaches for a solo, you have the option of playing:
-> G major for that entire 2 5 1 segment.
-> "Playing the changes" using the different notes for the different modes - dorian over the ii chord, mixolydian over the V chord, and Ionian over the I chord.
-> Or, knowing that the key for this song is G major, you could also play the relative minor = E minor, or even E minor pentatonic.
And of course, you can mix and match over the segment as well.
The thing is that for the next group of chords, the song could change key, so you'd have to go through a similar process again to figure out what key and modes are being used so that you end up playing the correct notes in your solo.