Hahaha, I used Rit dye a long time ago to dye tiny plastic pearls. The plastic absorbed the dye quite well, so I would assume pearls would be even more receptive. You’d just need to experiment because I’m thinking you wouldn’t want your pearls too dark.
Here are the plastic pearls I dyed black...