Letting them free-range is not going to help with keeping them in when you want them to stay in, it might make it worse. Bird netting can be draped over a run to keep them in. My predators are so bad, I have to have over the top run covered.
But yes you can get them in with a long stick. It is a case where slow is really faster in the long run. Pour a little treat just at the gate, and a larger pile further inside the run. Then take your stick walk out farther than the furthest bird. Tap the ground and say hut, hut, and walk toward the birds until they naturally move away from you toward the coop. Once they move, you stop, stay stopped until they stop moving. You don't want to chase them or get them riled up, you just want to lightly pressure them so that they move away from you toward the treat.
When they stop moving, then you take a step or 2-3 again toward them, saying hut, hut, with your arms outstretched, and tapping the ground, if one gets behind you, ignore that one and keep working on the others. That one will come back. You move til they start moving, and stop, when they stop, you start moving. Eventually one will see the treats, and the late ones will see the ones further in.
It can be done, and without upsetting your chickens.
But I don't think it will solve the flying out of the run problems.
Mrs K