AI can’t create it just copies ,like the Chinese
It does it the same way human musicians do, both are trained listening to and reviewing music, and use their training experiences to generate new melodies, but these new melodies come from what they’ve been exposed to and have taken in, its just the ai’s can be trained faster and on a lot more input
It doesnt mean everything they generate is awesome or good, just like human creators, not all songs are hits.