2 Allay "undying" bugs
1st bug: If you will summon allay with "summon minecraft:allay x y z {HandItems:(item)}" or change his data using "data modify entity (Allay) HandItems set value {(item)}", allay can die.
2nd bug: If you will give allay "Totem of undying" and he will die (lightning bolt, zoglin, TNT, etc. (BECAUSE PLAYER CANT KILL ALLAY WITH ITEM)) he still will be deathless