This is a common and useful expression in spoken English. It also describes a certain type of stubborn personality. It’s not really a good quality, but it’s a character trait that many people have.
If someone always has to “have the last word” it means
that when that person is arguing, they never will admit that they lost. They will keep arguing until the other person stops talking. They need to be the person who is the final speaker.
Imagine a husband and wife having a silly argument about almost nothing.
The husband might be wrong but really stubborn. His wife might say something like, “well, I really don’t agree with you, but I can’t really say anything because you always need to have the last word“.
Listen for this on TV and in movies. Ask your native speaking friends or teacher about it. It’s common and useful. If someone won’t let you win an argument, you can ask, “why do you always get the last word?“