If you want to hear music from youtube while doing other stuff on your phone, there is an easy way that has nothing to do with youtube music or something.
Open google chrome on your mobile phone and search for youtube.
When you are on youtube you must click on the three points in the right upper corner and activate the desktop mode.
If you want to repeat the video automatically you will need to put it in a playlist and activate repeat.
If you only want to hear it once you can just click on it.
Then you can go to your home screen, BUT DON'T CLOSE THE TASK and pull your (I don't know what it is called in english but you will understand) upper bar down and just click on play.
That's it, enjoy your video our your music.