Imperial guard operate on the following rank system, though the names of specific ranks will vary from regiment to regiment.
Trooper - Basic grunts with lasguns, making up the billions of infantry in the guard. Equivalent to privates, they have no subordinates.
Sergeant - Non commissioned officer that leads a squad of men. They have extensive battlefield experience and an aptitude to leading their troops, but no formal officer training.
Junior officers (Lieutenant, captain etc) - These are the trained officers that lead a section (usually around 50 men each), and will have a number of sergeants as their subordinates.
Senior officers (Majors, generals etc) - These are the veteran officers that lead entire army detachments, and have authority over the attached armour and support assets such as tanks and valkyries. Their immediate subordinates are the Junior officers commanding each section.
Beyond this you then have the officers that command entire fronts of a military campaign, with troops stretch across entire planets or even systems.
Outside of the military ranks there are specialists attached to a unit or fighting force, such as Commisars, Psykers, Ogryns etc. These specialists are generally not allowed to hold rank within the Imperial guard, with only a handful of known exceptions (Commisar-Colonel Ibram Gaunt of the Tanith 1st and Only being one of the more prominent ones). Specialists are generally unable to order around the individual assets of a fighting force - e.g. Commisars are there to make sure discipline and protocol is stuck to, not to make tactical decisions. Enginseers may issue edicts as to the use blessed machine assets, but may not order them around. None would be more suspect and shunned than battle psykers, who will be kept secure by their keepers both to stop them getting attacked by troopers and to keep the troopers safe.
As to who would take over if a sergeant is incapacitated, although it would have no mechanical gameplay effect a Sergeant will often appoint a 2nd, equivalent to a Corporal, that can help with issuing orders and maintaining discipline within the unit. This would typically be someone who shows basic aptitude for command and has some battlefield experience.