Something that helped me when I faced this issue:
I, too, was trying to do something on my iPhone, and couldn’t due to a restrictions passcode I was SURE I had never set up. I tried all the passwords I could think of, with no luck. I even found a trick that if I turned my clock setting off automatic and manually moved the time up, it would give me more guesses (I think this has been corrected in future iOS updates, but you can try it). I could NOT figure out how a restrictions passcode had gotten set up. Finally, I remembered that my iPhone passcode was different on my first iPhone I ever owned. I realized that, even though I truely had not ever set up a restrictions passcode on this iPhone, I thought, just maybe, that I set one up a long, long time ago on my first ever iPhone. After some soul searching and several wrong guesses, I finally remembered my first iPhone passcode, which was what I had also used for my restrictions passcode (luckily). Although my iPhone passcode had changed over the years, my restrictions passcode stayed the same. I still don’t remember setting up a restrictions passcode, or why I would have wanted to, but this method worked for me.
Try to think back to your first ever iPhone, iPad, iPod, etc., and ask yourself, “If I, in a moment of idiocy, decided to set up a restrictions passcode, what would my 10-year younger self have used as a four-digit passcode?” For me, it was the month/year I bought the phone, which I was able to find out by looking at old emails and records.