Searching Canon India's website for a lens repair facility, there does not seem to be an actual Canon Service Center anywhere in the state of Karnataka. All of the locations listed for various cities in Karnataka state are Collection Points that appear to be third parties affiliated with Canon in some way (such as a dealer for Canon copier products). These businesses probably don't repair any Canon lenses, but forward them to an actual Canon Service Center.
If you look at the listings for Delhi, for example, you see there is a Master Service Center listed. I would contact whichever such Master Service Center is nearest your location (I'm not familiar with the geography of India - there are also Master Service Centers in Cochin and Andheri) and inquire from them if the EF 50mm f/1.8 STM can be adjusted the way you need. There are also a few Authorized Service Centers and Authorized Service Franchises located throughout India. If one of those is much closer to you than a Master Service Center, you might try contacting them.
If it turns out the lens is not adjustable, then you might consider having your camera checked to see if the PDAF sensor array is properly adjusted to be the same optical distance from the lens as your camera's imaging sensor is.