@Mojoj
What a load of mince. You need to pick her up as she can't walk home in the dark. You tell her to ignore the detention. When you're called up about it, you reiterate why it's not possible and tell the school you will exact punishment at your convenience. I would also complain about the attitude of the teacher you spoke to. He sounds like a dick.
& the school will simply add the dd to the 'didn't attend detention' list & move on to the next sanction.
It would not be fair of the school to expect parents to 'exact punishment'.
What if, following a sequence of incidents of two kids clocking up enough behaviour points for a detention, Anna's parents are horrified that she's stepped out of line & ground her for a month, but her best mate Badriya has parents who think that whatever shenanigans the two of them got up to is no big deal, so they laugh it off?
That's not fair, obviously, & it's outside of the school's control. Different parents will take completely different lines regarding their behaviour expectations of teenagers & how they manage that.
What the school can do, & all they can do, is deal with behaviour on their watch, & insist that both of the girls serve a detention. & if Badriya doesn't show up for it because her dad has told her that he's decided that she doesn't need to, then, well, Anna will be back in lessons on Monday, & Badriya will be in the isolation room.
Rules have to be as fair & consistent as possible. Schools generally try to enforce them fairly.