Try entering the target PC’s local account as TargetPCName\Username (not your Microsoft account email). If that fails, go to Credential Manager → Windows Credentials → remove any entries for that PC, then re-add with correct password. Also ensure both PCs are on a Private network with discovery turned on.

Complete Guide to Managing Network Credentials in Windows 11