A couple months ago, I ran across the word bodhisattva ("a being that compassionately refrains from entering nirvana in order to save others and is worshipped as a deity in Mahayana Buddhism") and learned that the Sanskrit word bodhi means enlightenment. This reminded me of the character Bodhi Rook in Rogue One: A Star Wars Story, so I watched the movie again to see what connection the word and its meaning have to the character (also because I recently finished watching Andor, which immediately precedes Rogue One chronologically).
If the character's name is meant to indicate an enlightenment, this enlightenment (the realization of the Empire's oppression and terror) seems to have occurred before the events of the movie. By the time Bodhi appears, it's well established that he has defected from the Empire. He tells Jyn, "Your father, he said I could get right by myself. He said I could make it right if I was brave enough to listen to what was in my heart. Do something about it." While the actual moment of his enlightenment isn't shown, it continues to motivate his actions.
---&---
For what it's worth: this isn't the first instance of Sanskrit in Star Wars. There are some Sanskrit words in "The Duel of the Fates" near the end of The Phantom Menace. At about 3:11 in a featurette titled "Movie Music," John Williams explains to the choir that "I've chosen these Sanskrit words because of the, the quality of the vowels."