The answer is "it depends."
First, proceed as described under "If you still can't reset your password, erase your Mac" in If you can't reset your Mac login password - Apple Support, after which you can attempt to restore that Time Machine backup. You will be asked if you want to transfer information subsequent to erasing the Mac and reinstalling macOS, so the TM backup will be the source.
If the Time Machine backup was encrypted with a password then the answer is no, not unless you know that password. If you do not know whether the TM backup was encrypted or not it is a moot point anyway because the only way to determine that is to follow the above instructions.
... and then copy the files to a Windows PC?
That would be the next step, but it's getting ahead of ourselves. Restore the Mac first.