Like Siri, Shazam can't recognize a tune that you sing or hum yourself. If you don't want to use Google for that, then try the SoundHound app (Android or iOS). If you have a Pixel 2 or later Google Pixel phone, there's a handy feature called Now Playing that's built in.