Code requirements often change over time.
As many older sub pumps were installed without a grounding conductor, I anticipate the thought at the time was, since the pump is located down in a well, fully submerged in water that is in direct contact with earth, the pump will be effectively grounded.
Because pure water is not an electrical conductor, it is the various salts and minerals dissolved in the water that provide electrical conduction. As the amount of minerals and salts can vary widely between different wells, there is a potential for a less effective 'water ground' to be created in some wells compared to the same pump installed in an alternate well.
Most electrical codes now require all grounds to return to and terminate within the main electrical panel. Adding a dedicated grounding conductor from the sub pump (and metal well casing), back to the main electrical panel, will ensure the pump and well casing will utilize the same common ground reference connection as the entire electrical system.