The area that we did our container gardening in was behind some portables, enclosed by the portables and 3 sides of chain link, with a gate. In addition to gardening, we'd also hatched some eggs. Students whose parents agreed took home the chicks after a few weeks. One of my students lived next door to the school. He literally had a gate on his back fence that opened directly onto the playground.
We (teachers) were back in August the following year, in meetings preparing for the coming year. We were in a section of portable classrooms. I came out during the break to see our custodian and some groundskeepers chasing a rooster up and down the ramps and aisles between the portables. It was pretty entertaining until they caught him and locked him up in a storage area. Just when they were taking him away, my student arrived, red-faced, crying, and yelling, "No, he's mine. You can't take him!"
This chick had turned out to be a rooster, and the neighbors complained. So my enterprising student, who had just finished 3rd grade, built himself a coop in our old container garden and kept his rooster there, where it was an easy trip across the playground to visit and care for him, and he had the garden to hunt and peck in.
The groundskeepers were surprised, when they opened the gate to do a general clean up, to be met by the rooster, who, confronted by strangers, made a break for it.
So the student, the groundskeepers, custodian, PTA president, and I all got into a tense debate about whether or not the rooster could stay in the garden. It was decided that, no, the rooster couldn't stay. The PTA president promised to take him to her brother who lived outside the city limits, where he could live out his life happily with the brother's hens. It was a compromise. My student was relieved that his rooster wasn't about to become dinner, but not consoled about his loss.