The first step to connecting via ADB is to make sure your workstation can see the device. If you are attempting this within the VM, make sure you have passed the device through to the VM via USB devices. If it’s still not working, unplug the phone and plug it back in. You may have to enter the password if the device has not been trusted with that workstation in the past or if USB authorizations have been cleared on the phone.
The screenshot on the left shows this issue. Nothing appears when you type adb devices. The screenshot on the right is what we expect to see when we successfully connect an Android device and have authorized the USB to trust our workstation.