This is so damn stupid. Your music teacher is a moron and you are too for actually mulling it over enough to bring it to the public forum.
Believe it or not, some musicians, if not a lot of them, write music and perform it because they enjoy it! A lot of the time they will have jobs and if they get paid for playing, it's like a bonus. It's not like if people keep downloading then all of a sudden music will cease to exist. Pubs won't go without their pub-rock bands, restaurants won't go without their pianists or string quartets. Besides, even if musicians did "boycott" production of songs, how would that help their financial state anyway? All they'd be doing is taking from themselves.
So many bands don't even give a shit about people downloading their music. Why? Because they're stoked enough that the person has gone out of their way to somehow obtain the album. If that person likes the album then surely they will see the band when they tour or they'll buy a shirt or something. If that person doesn't like the album then the band doesn't want them to spend their money on something the person didn't like. Some bands even release albums for free! These are the sort of bands that nobody talks about when it comes to piracy. These are the sort of bands that care more about people hearing their music than people buying their music.