Here we can see how it works.
Blue lines show the edges of the triangles that face the light and cast
shadows.
The shadow volume is paint in yellow.
The resulting shadow is shown in red (in orange due to the blending with the
shadow volume).
Same view without the shadow volume.
And the final result. The shadow is blended with the background.
The plane is also casting shadows on itself.