If you see a bunch of duplicate songs in the “Downloaded” playlist in your iPhone Music.app, then there is a chance that you have manually dragged music files to your iPhone icon in iTunes or Finder to add them to the Library before Apple made a change in how these music files were marked. You will need to delete these music files from the iPhone to get rid of duplicates. This can be done by un-sync-ing your Music, deleting all Downloaded music, then re-sync-ing.
- Connect your iPhone to your Mac
- On the Mac, open a Finder window, select your iPhone from the left pane
- In the right pane, select the Music pane
- Un-check “Sync music onto… iPhone”
- Click “Sync” on bottom right; All sync’ed music should disappear from your iPhone
- On the iPhone, Go to Settings > General > iPhone Storage
- Swipe “All Music” to the left and delete all the music that is Downloaded to your phone; Now you should only have music tracks you’ve purchased from the iTunes Music store that are on the cloud
- On the Mac, go back to the Finder window with the Music pane
- Check “Sync music onto… iPhone”
- Click “Sync” on the bottom right; All or Selected music will be transferred back to the iPhone
Now there’s going to be a problem if you downloaded music to the iPhone from another source, like another Mac. But if you were smart enough to do that, you can probably think of how to get around it.