It’s not quite that. But I believe there’s been a shortcut taken in the doc because of the use of the directional light (which is recommended for shadowing, but not the only way of casting shadows).
In case of a directional light, the direction is in fact the coordinates of the targeted shadow. The position of the light should not affect the shadow direction/target AS LONG AS the positioning of the light is still in range to actually be able to cast a shadow on the mesh. Eventually at some point if you move your directional light position out of range without changing its direction, the mesh will simply not be shadowed anymore.
Take a look at this PG from the doc, where on line #8, I changed the position of the light to 25 on the z-Axis. Now you can see the shadow only takes the feets of the model. Push it further to say 30 and the shadow will be gone. So there’s a relation between where the light starts (the position) and where it is targeted towards (the direction). This is particularly obvious when using things like contact hardening shadow or when using different types of light for shadowing.
The parameter direction is the offset of each point of the shadow relative to each vertex of the model, and the position of the parameter affects the generation of the shadow