The man was discovered 30 minutes into the flight, most likely when the flight attendants unlocked the bathroom door to allow passengers to relieve themselves. The 25 year old man was not carrying his passport, as the cleaning firm he was working for, had taken it away from him (most likely to prevent an incident like this).
Air India points out that there was no real reason for concern, as the man had to clear airport security before he could go to work. Once in India, he was arrested and booked under several sections of the passport law. It is very unlikely that they’ll send him back, since he is an Indian citizen. The procedure for getting the plane ready for passengers only involves an announcement asking ground crew to leave the aircraft, and not an actual check that they do so.