1. The people who made the music sold the rights to the music to the people who own the music, who then licensed the music to Spotify for an agreed-upon amount. Everyone agreed, presumably because this deal was beneficial for every party involved, which it most likely is otherwise Spotify wouldn't have been able to obtain licenses to almost every artist's music.
2. There will never be a shortage of art in this world, whether it's compensated monetarily or not. This is probably an unpopular opinion, but I don't see a big need for artists to be compensated. If they stopped being compensated, we'd just be left with a few million artists of every medium producing art for free because that's what most artists do, whether it pays or not. If they weren't compensated, there would be less mass-market art, but since the quality of art is both subjective and relative, we'd probably all be just as satisfied with it.
If you stop compensating most professions, their output drops to zero. If you stop compensating artists, they just keep producing art. One could argue that we'd get even better art if we stopped compensating artists. We'd be left with nothing but the passionate ones.