I thought you meant this was done by a law enforcement agency, schools can and often do punish children for behavior problems and do not have to notify you immediately. The rules placed upon schools are a bit different from law enforcement when dealing with juveniles. The school authorities could not question your daughter without representation or you being present if they were working for law enforcement to solve a ciminal matter, but they can question a student to investigate a rule infraction and the juvenile does not need to be represented. Now, if they locked her in a room alone and depending on the other things they did to her, this could be considered cruel punishment and in that event you should make a complaint
to the school board. If they believed your daughter was involved in some crime, then they should have notified the police and you. If they were merely punishing your daughter for a school infraction, while the means seems a little bit overboard, which would justfy a complaint to the school board, but schools punish students for rules infractions with in house detentions, in house suspensions, regular suspensions and expulsions and this is within their rights.
Responsible schools notify a parent when there child is involved in a disciplinary incident, but you would have to refer to your local school board rules to find out the school policy on it. You certainly still can complain that the method they used was abusive.
If you found my answer helpful, please click on the GREEN ACCEPT button. Your question will not close, and you will still have the opportunity to follow-up if needed. Leaving a bonus and positive feedback is not required, but doing so is certainly appreciated!