For the loopback adapter to function correctly for testing (so it doesn't rely on DHCP), you should assign it a static IP address.
You can now bind software to this IP address to test communication between virtual machines or services on the same machine without a physical network cable. microsoft loopback adapter windows 11
# Run PowerShell as Admin
pnputil /add-device "C:\Windows\Inf\Netloop.inf"
Note: This installs silently; rename the adapter via GUI or netsh afterward. For the loopback adapter to function correctly for