It depends on the breed of dog, as well as its health. Smaller breeds mature faster, but age more slowly after reaching maturity. A small dog (such as a toy poodle, terrier, chihuahua, etc.) isn't considered "geriatric" until much later than a larger breed - maybe 10 to 12 years old, and the largest breeds are senior citizens at 5 or 6 years of age. Most vets, though, consider a dog 7 or 8 years or older to be a senior citizen.
Some 'senior' dog foods are basically marketing hype, with little difference between the regular food and the senior food. All young dogs should be fed puppy food as they have very different requirements to adult dogs, but whether or not an older dog is switched to senior food seems to be a matter of the owner's choice as often as the dog's health.
The switch to senior food should be considered carefully and your vet should be involved with this decision. Some dogs become less active as they age and therefore need fewer calories and nutrients. Other dogs need more due to poor digestion. Senior foods that can be bought in supermarkets rarely describe exactly what is in them compared to that brand's regular adult dog food.
If your older dog has specific health problems (such as failing kidneys, diabetes or poor absorption) it will need a different blend of nutrients to healthy, younger adult dogs that may or may not coincide with senior foods. Senior foods may help older dogs to live happier and healthier lives, but they may also be unneccesary wastes of money. Also, the foods that contain less energy and nutrition may be detrimental to the health of dogs with poor digestion.
The age at which each dog should change food will depend very much on the individual situation.