I don't think this is a Larian plothole.

First of all Rafael doesn't asks for any soul, he offers his alliance and shows interest for the tadpoles, nowhere in the dialogue I had the sensation he was trying to make a devil's deal with the party.

My second point is about the idea of undead. It is flawed. It is based on the duality between body and soul (where soul includes not only emotions and feelings but also rational and logical thinking).

So I get a zombie as an undead: it is a corpse of a dead that by some reasons (usually magic, sometimes scientific) becomes animated, but it lacks anyform of intellect and feelings.

On the contrary I can not get the idea behind other forms of undeads like lichs, skeletons, vampires. At least not without consider them dead bodies (at different stages) infused (usualy by a curse) with a soul that is forced to remain in that container, a curse that comes with different requirements to maintain their form and delay the final judgement of the related pantheon (for liches is to feed on soul energy, for vampires is to feed on blood), due to the curse and the fact that the souls inhabit a dead body (a corpse) to me it's only natural that they rely on the worst aspects of human nature and that they have to struggle to avoid going feral.

Let's take for example the White Wolf set: there a soul leaves a body when a human dies, but if they are killed by a vampire and embraced the soul fall under the curse of Caino and remain entrapped in the corpse, in the Buffyverse the soul leaves the body but it becomes replaced by a demonic one.

I think the incoherence is in the D n D set that didn't explain explicity how vampires function and in the fact that the authors were probably influenced by the modern trinity that is body, soul, brain. With the soul being related to feelings and emotions, the body to instict, the brain to logical and rational thinking. So the soul can leave the body and a vampire (or an undead) can still act not like a feral beast,because the precence of an intact brain allows rational thinking and also to mimick emotions (that would explain why D n D vampires and undeads show emotions and feelings and why those are twisted).

Furthermore the fact that a curse could force a soul into a corpse would not break the fact that souls need to pass judgement by the Faerun pantheon, and won't lower the income of souls the demons need for their wars because vampires and undeads supposedly are rare monsters.

Nevertheless Wizards of the coast should meke esplicit how undeads function.