Failed to add my iphone as second device

I guess there can be rare cases where same-wifi connections don’t work because of the way the WiFi is configured.

You might try opening a Wifi hotspot from your iphone and let your laptop connect to it, and then do the add-second-device workflow.

If this also fails then exporting a file from Desktop and importing in iOS is the last option. See here for some more details: Import backup to iOS