The official way to use copyrighted music on YouTube is through YouTube Studio > Audio library. The audio library includes free music and sound effects, some of which don't even require attribution.
The recordings, which are taken from all over the world and date back to the 1920s, are divided into categories including ‘Footsteps’, ‘Machines’, ‘Crowds’ and ‘Events’ The BBC’s sound effect library ...