How do you do Lightning Reversal in Sekiro: Shadows Die Twice?

Quick answer: When an enemy throws lightning at you, jump so it hits you in the air, then attack before you land. The lightning flies back and stuns the enemy.
Show walkthrough (quest spoilers)
When you learn it
The game teaches Lightning Reversal in the final phase of the Genichiro fight on the roof of Ashina Castle. When Genichiro, Way of Tomoe starts using lightning, a tutorial appears. It is not a skill you buy; anyone can do it.
How to do it
Watch for the enemy to raise their sword and charge lightning. Jump so the lightning strikes you in the air, not on the ground. Then attack before you touch down to throw the lightning back.
If you get it wrong
If you are on the ground when the lightning hits, you take big damage and are left stunned. Jumping too early also fails if you land before the strike. Practice the timing on Genichiro’s charged strikes.
Why it matters
A reversed bolt deals heavy damage and stuns the enemy, giving you free hits. Later lightning users in the game can be beaten the same way. How to beat Genichiro.
