I said no and I feel like a criminal

Im currently in school to become an RECE, Today I had an issue at the place I’m at: The other staff in my room said that an area in the play ground was closed. A child kept trying to pull off the lid of this closed area. Trying to help in the moment I firmly said “ No, this area is closed” because that was the first thing that came to mind. I got in trouble with the supervisor and was told I can’t say no. I understand we should first use positive reinforcement by redirecting but at the moment I hadn’t had the time to think of that. Another person had said I was yelling at the child. I was not. I was told if I do this again I will fail. Thoughts?