This is almost always caused by one of two things.
1. The water in their waterer is too hot and they don't drink or another bird is bullying them off the water. When quail don't consume enough water they can suffer from nerve damage and will often be unsteady or fall over. Sometimes they even walk backwards or get weird twitches too.
Nerve damage can heal in some cases but often the birds have to be put down. Usually birds will stop eating and drinking when they have this issue.
Check the temperature of their water with your finger or a thermometer. If it's up around 90* or more they won't drink it. Most water fonts get pretty hot if they are in direct sunlight so it's best to try to place them in the shade.
2. They hit their heads on the ceiling. Brain damage/cranial swelling will make quail walk badly, fall over, twitch, walk backwards or walk in circles. This is the cause of that type of behavior in most cases.
If separated and kept warm while getting free access to food and water these things do sometimes heal. You'll also want to add a vitamin supplement to the water like VitaSol or SavAchick.
Otherwise you may want to consider processing them while they are still alive and it is safe to do so. If they die on their own, do not eat them or feed them to your animals.