Im trying to factory reset my samsung, and to do so the phone needs to be completely off. Im trying this because I forgot my password, but I cant force shut down my phone without putting in my password.
Welcome to the forums. That is a very important security measure to avoid that if someone steals our phone they can't simply wipe all data and have a fresh running device in their hands. Your password/pin is necessary to decrypt and get into Recovery, there's no way around this.
The password would be the same as your screen lock. If you don't have one set up, this shouldn't be a problem. If you do have one set up, then I'm not sure how you could have forgot it. Even if using biometrics, Android occasionally requires you to use your PIN/password (which is required as a backup anyway). PINs and passwords are not to be taken lightly.
Samsung devices require the password entered regularly even when biometrics are set up so unless you let this sit in a drawer for months I'm not sure how you forgot it.
This is something I love about my Samsung phones, if someone steals my phone they can't shut it off to prevent me from tracking it.