Veil buff applies on self or allies to avoid being targeted by enemies. However, champions that have Veil or Perfect Veil buff will still get damage from enemy's AoE attacks. There are two versions of Veil (Veil and Perfect Veil). The difference between Veil and Perfect Veil buff is that Veil will be removed whenever the champion who has this buff inflicts damage to its target while Perfect Veil will get to remain hidden from targeted after performing an attack on its target.
The Veil effect will remain even though you cast a Debuff on enemies without any damage on top of it. Veiled champions can still be hit by counter attack.
The champion who has Veil buff can be targeted if it’s the only remaining champion in the team or if all champions in the team has this buff.