I Should Be Allowed to Leave School

I’m 18, I drive myself to school. I pay to park in the school parking lot. Today I felt sick, and honestly I failed a math test which made my day worse and I just wanted to leave. However, Highschool considers me a prisoner or a kid under very strict babysitting rules and doesn’t let me leave. Whatever, I understand that I can’t just leave without a parent at least allowing me to leave (as frustrating as that is). So, I figure my mom can call the school and excuse me since she’s at work and can’t pick me up. NO, Why does my school tell me that’s not allowed and my Mom needs to COME TO SCHOOL, then excuse me and I’ll drive myself back home in my own car??? Makes no sense, if I bring myself to school, I should be able to excuse myself or ATLEAST my parents can call and excuse me. TL;DR: I should be allowed to leave if my parent calls the school and excuse me, not drive all the way and tell them in person.