I faced the same problem in Xcode 16.1. These two solutions worked for me, but I must repeat them every time I add a new Swift package (SPM).
The first way:
When you are on the loading SPM screen, press Command command + delete/backspace to clear the SPM history.
Clear the history. [enter image description here][1]
After that, I can add a new SPM.
The second way:
Close Xcode completely. Ensure it’s not running in the background.
Open the Terminal and run the following command to remove cached Swift Package references: plutil -remove IDESwiftPackageAdditionAssistantRecentlyUsedPackages ~/Library/Preferences/com.apple.dt.Xcode.plist
Reopen Xcode and your project. You should now be able to add a new Swift Package without any issues.