Good afternoon azjules,
Welcome to the Apple Support Communities! We understand that if you lock the screen on your iPhone music will stop playing. We know it's important to be able to listen to music with a locked screen; we'd like to help. If this is affecting the Music app, take a look at these steps first:
If the behavior continues, we'd also suggest removing and redownloading the Music app to your device. Please keep in mind that this will remove any content you've downloaded and will need to be downloaded again:
- On your iOS or iPadOS device, touch and hold the app.
- Tap Rearrange Apps.
- Tap in the upper-left corner to delete the app.
- Tap Delete. Then on an iPhone X or later, tap Done. Or on an iPhone 8 or earlier, press the Home button.
If you have an Apple Watch, deleting an app from your iPhone also deletes that app from your Apple Watch.
- On your iOS or iPadOS device, go to the App Store.
- Search for the app. Make sure that you use the exact name of the app. Find the correct name of built-in apps.
- Tap to restore the app.
- Wait for the app to restore, then open it from your Home screen.
If you have an Apple Watch, restoring an app to your iPhone also restores that app to your Apple Watch."
Delete built-in Apple apps on your iOS 12, iOS 13, or iPadOS device or Apple Watch
If the behavior doesn't occur with the Music app, but other apps are affected, please let us know which apps you have trouble with.
Take care.