Why Do Drivers Flash Their Headlights?

Why do drivers flash their headlights?

I have noticed on several occasions that whilst teaching a new driver how to emerge from a junction that another motorist will ‘flash their headlights’ to apparently let the learner driver go first, even though it’s not the learners priority.
‘So what you might’? ask, Yes a common enough situation, but what happens next is the puzzle.

The learner driver takes a few seconds longer to react than a qualified driver would and the guy who flashed the lights races off in a puff of smoke as if late for tomorrow.
Question: If the driver who flashed was in such a hurry, why stop in the first place since the priority was theirs?
A lot of the time if the driver who offered to let a learner driver go first was to look in the rear view mirror would see the road to be clear behind and the learner could have moved away anyway and no one would be confused. Especially as I now have to explain the Highway Code rule on flashing headlights and priority’s to the learner driver. But why the driver flashed I still could not say.