Question: how to transfer music from itunes library to icloud?
Answer: Open iTunes.
From the menu bar at the top of your screen, choose Edit > Preferences.
Go to the General tab and select iCloud Music Library to turn it on. If you don't subscribe to Apple Music or iTunes Match, you won't see an option to turn on iCloud Music Library.
Click OK.