This is good advice for students who speak native AAE because there exists bias against the dialect. It's better for their own, personal life trajectory to adapt to the way that the world will judge their dialect.
However, that doesn't make it okay to continue to perpetuate the idea that AAE is somehow a lesser dialect and that AAE speakers ought to have to mask their accent in the way that an Indian, Brit, or Australian doesn't.
We can simultaneously teach students how to navigate the dangers of the world they live in while trying to fix said dangers for future generations.