Did you use any VPN?
In the Xcode Bata Release Notes, they mentioned:
Xcode 15 may not be able to communicate with devices running iOS 17+ and tvOS 17+, and watches paired to iPhones running iOS 17+ with certain VPNs active. (110337781)
Workaround: Disable the VPN to interact with the device and reach out to the VPN vendor for resolution.