While the playing time of a quarter is 20 minutes, unlike something like soccer, the clock doesn’t count up and also doesn’t just continue to run. The timekeeper will stop the clock for stoppages.
Stoppages occur frequently and for a number or reasons including goals and behinds being scored, injuries, the ball going out of bounds and the umpire call for a ball (throw) up.
This means that while a quarter will contain 20 minutes of play, in real-time it can fluctuate significantly. On average a quarter will last around 30 minutes.
Interestingly, while the timekeepers count the time down, the scoreboard at the ground will display a clock that counts up and will run continuously from the start of the quarter, so fans in the crowd won’t know how long is left in the quarter. This that will the clock counting up, any time after 20 minutes appears to be time that is added on, known as ‘Time On’.