Character voice is a hard topic to master and practice. A lot of it comes down to a couple of things. One being most writers can’t seem to tell if their characters sound different. And the other is how writers see dialogue.
Writers can show a whole world, describe conflict, and trick the reader just by fine-tuning a character’s voice to make it sing. How someone chooses to express their emotions, surroundings, and the situations they get into can convey way more to the reader in a more engaging way than simply stating it.
Nondialogue voice or your character’s inner voice is usually done in a way that aligns with how the character speaks with the rest of the characters in the story. But sometimes an author wants to show that a character has extra depth or perhaps isn’t who they appear to be to the reader or other characters in the story.