How to download apps on icloud and not my phone?

I bought extra icloud storage and now have 50GB and my phone memory is only 16GB. I have like 3GB left on the phone memory but still all that storage left on icloud.

How do I download my music app through icloud so that it uses the icloud storage instead of my phone storage? Is this possible?

I found one of those free song apps and was wondering how I could download it to use my icloud storage instead.

No. It can't use the icloud (Internet) data in real-time.

Unfortunately that's not how it works

It doesn't work that way. The cloud storage can only be used to store your app documents and maybe app data, pictures, videos, etc. You can't use it to store actual apps.