YouTube pays the labels less (the labels/artists see YouTube as more of a promotional tool than Spotify).
Plus, YouTube doesn't only have music, most of its videos are user-content which is free to YouTube.
Youtube is driven by user created content, while also paying much much less to copyright holders. Not to mention, Youtube is also immensely more popular than Spotify. The numbers don't even come close. Also, being owned by Google/Alphabet doesn't hurt.