On a Mac, the Activation Lock can be disabled by using the Apple Account and the Apple Account password.
If you can not access the Find My settings in the iCloud settings on your Mac, you can also disable the Activation Lock on the Internet by logging into your iCloud Account:
...
- Go to www.iCloud.com/find.
- Sign in to your Apple Account.
- Select the Mac that you want to remove from iCloud.
- Click Remove.
...
copied from: Activation Lock for Mac - Apple Support
In case this is about the user account password on your Mac, this can be reset as well:
If you forgot your Mac login password - Apple Support