By password, do you mean it’s requiring your google account password?
If you forgot that and your phone is registered with your account there’s no way to get it back.
However if it’s only your pin you forgot you can always reset your phone by holding down the power and volume up, waiting for it to shut down and vibrate, then releasing the power button, but keeping the volume up until you see the “no command” screen. Then pressing volume up and power again for 5 seconds and selecting the “reset phone” option.
Hope that helps.