From: Use parental controls on your child's iPhone, iPad, and iPod touch - Apple Support
Make sure to choose a passcode that's different from the passcode you use to unlock your device. If you can't remember a restrictions passcode that you set on a previous version of iOS, or you forgot your Screen Time passcode, you need to erase your device, then set it up as a new device to remove the passcode. Restoring your device from a backup won't remove your passcode.
The restrictions passcode is contained in any backup made after it is put in place, so unless you have a backup from before you set the passcode, you will not be able to use the backup to restore to.