When you are in Shazam, look at the top right hand side. You should see a button labeled "Auto Tag." Make sure it is turned OFF and that red line will disappear when you go back to your homescreen.
If you don't want to turn off the Auto Tag feature, you can fully close the app and that will make it stop also. To do (apologies if you know) - swipe up with four fingers (or double click the Home button) to reveal the app-running cards. Find the Shazam app card and swipe on it to dismiss it. That red bar should then be gone.
Hopefully, one of these two ideas will be of use.
Marilyn