Those are fire attacks so do nothing to the imp, the lash of hellfire is not a lash which burns but just out of fire so it is only fire not a lash itself. So there is no physical contact. How does the army get it away?
The point is if a weapon has a damage type it means it is that type of attack. A gorgon archer for example has no poison type attack, it just has a poison effect. In a way it is a "physical" arrow which is impoisoned, so the arrow itself will still deal damage. While other attacks are the type itself (hard to understand if you think to physical) so lets take the fire elemental before the firebrand imp.
So this is an incorporeal fire thing, if it wants to attack the mage (behind the fire immune guard) the flames are "absorbed" by the fire immune creature and it can't pass to attack, and it does deal no damage to the imp either due to the immunity. The same counts for even more creatures. You talk about many creatures ok, if you are next to a wall you are definitly save as there are no other directions you could be attacked from apart from there where the imp protects you. Creatures have no direction of sight, so we could all imagine walking around.
No comes the more tricky part, you have a firebrand imp (we now only consider melee attack) which aparently also has a fire damage typ but his claws apear to be "physical" but its not different than the elemental it is also just a manifestation of mana and mage energy. The same as a suppresion cloak wizard which is guarding against 0-1mana oposing mage can protect everything in its zone. "It lacks the converted "vtar (magic)" to be able to achieve anything" In the imp case "its vtar (magic) has the wrong manifestations, a simple tanglevine or force push could solve the issue"
This is mage wars, magic is extremly logic
Conserning the trageting: The magic is universal, all taken from the v'tar pool whatsoever, so if you would target the imp with a circle of fire. That type of magic is "repulsed as it is does not enter this eternity where flames can't be", same counts for all these other target restrictions
coming back to balance here: This "feel of repulsion happens before counter spell, as this is an say it in jedi words disturbance in the force there which does not allow it (so no ghoul rot to trigger nullify on a necro). The targeting restrictions have to arise due to the fakt that enchantments are hidden, so you can't control if it would be an illegal move