Devil's Sight. Magical darkness doesn't impede the devil's darkvision.
Compound Eyes. Beelzebub has advantage on perception checks when he isn't blinded.
Magic Resistance. The devil has advantage on saving throws against spells and other magical effects.
Spellcasting. Beelzebub is a 20th-level spellcaster. Its spellcasting ability is Intelligence (spell save DC 22, +14 to hit with spell attacks). The lich has the following wizard spells prepared:
Cantrips (at will): mage hand, prestidigitation, ray of frost, infestation, chill touch
1st level (4 slots): detect magic, magic missile, shield, thunderwave, ray of sickness
2nd level (3 slots): acid arrow, detect thoughts, invisibility, crown of madness
3rd level (3 slots): animate dead, counterspell, dispel magic, vampiric touch, lightning bolt
4th level (3 slots): blight, dimension door
5th level (3 slots): cloudkill, scrying, danse macabre
6th level (1 slot): disintegrate, globe of invulnerability, soul cage
7th level (1 slot): finger of death, plane shift
8th level (1 slot): dominate monster, power word stun
9th level (1 slot): power word kill
Multiattack. The devil makes two attacks with their wand, or three with his claws, he then can cast a cantrip.
Lord of the Flies (1/day). Beelzebub awakens an amount of undead equaling 500 hit points. All undead conjured this way obey his command, are immune to Control Undead, and have Turn Resistance. As an action, Beelzebub can perceive through the senses of his conjured undead.
Wand of Zebul. Melee Weapon Attack: +15 to hit, reach 10 ft., one target. Hit: 15 (2d8 + 7) bludgeoning damage.
Claw. Melee Weapon Attack: +12 to hit, reach 10 ft., one target. Hit: 15 (1d6 + 4) slashing damage. The target must succeed on a DC 15 Constitution saving throw or be paralyzed for 1 minute. The target can repeat the saving throw at the end of each of its turns, ending the effect on itself on a success. Afterward, the creature is immune to the paralyzed condition from this attack.
Death Flies (Recharge 6). Beelzebub conjures a 15 ft. radius swarm of pestilent flies, creatures within the radius must make a DC 22 Dexterity saving throw. On a failure, the creature takes 2d6 piercing damage, and is infested with Death Larvae. After three turns the larva undergo metamorphosis, spawning 1d6 Death Flies within 5 ft of the creature, dealing 10d6 Necrotic damage to the infested, if this necrotic damage would cause the infested creature's hit points to be 0, then they immediately die and rise as a ghast under Beelzebub's control. On a success, the creature instead only takes half damage and is not infested. While infested, the creature can attempt to kill the larvae, to do so, they must either be dealt at least 20 fire or acid damage in a single turn, or targeted by a spell that cures diseases such as lesser restoration
Blood Ritual. On the same turn when Beelzebub kills a creature, he can use the Wand of Zebul to perform a Hemomancy Ritual on their fresh corpse. Until the end of his next turn, he cannot take any actions, his speed is set to 0, and he spends his time concentrating on the ritual. Once he completes the ritual, he can either restore a spell slot up to 5th level, restore 10d4 hit points, or, instantly recharge Death Flies, additionally, the creature sacrificed cannot be revived except through a wish spell. This ritual can be disrupted if either Beelzebub's concentration is interrupted, the corpse is displaced at least 60 feet from him, or if the corpse is sufficiently damaged.
Beelzebub can take 3 legendary actions, choosing from the options below. Only one legendary action option can be used at a time and only at the end of another creature’s turn. Beelzebub regains spent legendary actions at the start of its turn.
Cantrip. Beelzebub casts a cantrip.
Perception. Beelzebub makes a perception check.
Claws (Costs 2 Actions). Beelzebub uses two Claw attacks.