Also helps ensure the drugs are clean. The US marijuana legalization process has absolutely not been perfect but the regime of testing for pesticides and mold is very effective.
If cocaine were legal and regulated you wouldn't be hearing all these stories of people dying of fentanyl overdoses from doing shitty cut coke.