This might be obvious to most, something you automatically do. I’ve come to realizations of something that seemed so obvious after I learned or thought of it. So, I’ll explain a technique where you are the actor.
Observe how people behave. Watch how characters are done by actors, written in novels of course, etc. Then act that character out in your head.
Take Gir from Invader Zim. (Netflix Trailer. Gir talks at the end.) What would he say, how does he walk? If he says, “I saw a squirrel, it was going like dis.” and “But I need tacos. I need them or I will explode. That happens to me sometimes.”
I’ll create a new scene and add new dialogue never done in the show.
Gir wobbled and spun around. “It’s Tuberday.”
Zim squinted. “What’s Tuberday Gir?”
Gir frowned and looked up at Zim with puppy dog eyes. “I don’t know.” Running away Gir tripped. “I love saying Tuberday.”
Play the actor all the time. When you see or hear what someone says, try and come up with something else they might say like writing fanfiction. Don’t Plagiarize. That’s why you practice having another person’s character in a new location, situation, and saying something original in the first place. Once you create your own characters, you won’t be using what someone else already wrote.
Once you get many other characters down, you can do your own easier.
You can take acting classes. At the least, watch videos on YouTube about acting. You can translate this to your writing.