Does a plant have to be alive for its roots to prevent erosion?
The roots do actually continue to hold soil without being alie.  The stabilizing properties are structural in nature.  You begin to lose those though as the roots decompose, and the important roots against erosion, millions of fine root hairs, will go first. But leaving the roots in on a dead tree will help for a bit, but isn't a long term solution.