Everything you see and hear in Dreams is made in Dreams, including the music. As such, the game has a full digital audio workstation for you to faff around with, complete with sequencers, effects, and even processors, such as EQ plug-ins. This means that you can, essentially, create full songs within the software to insert into your own dreams or share with other players.
And for a demonstration of how it all works, check out the video embedded above. Here we see a Media Molecule employee pull in some samples, record a few performances with the DualShock 4, and essentially mix a theme song for a level being created inside the Dreams booth at PSX 2017. The ambition of this game is absolutely unprecedented.