The purpose of a timeout for toddlers / small children is to have a negative (but not harmful) consequence they understand so they can make a choice as to whether to continue a certain behavior or not. There are very few appropriate negative consequences available that a toddler will understand.
Punishment does have its place in behavioral training but is not the first or even third method to rely on. Parents should be first prioritizing on rewarding positive behaviors.
The criminal justice system is a terrible example of punishment used effectively. Punishment in behavioral training is best used in a very tight feedback loop (immediately after action, not after 5 years of court cases) and reliably.
Punishment does have its place in behavioral training but is not the first or even third method to rely on. Parents should be first prioritizing on rewarding positive behaviors.
The criminal justice system is a terrible example of punishment used effectively. Punishment in behavioral training is best used in a very tight feedback loop (immediately after action, not after 5 years of court cases) and reliably.