For example, you tell your partner that you like his new haircut because you don’t want to hurt his feelings by telling the truth that you really hate his new haircut.
My point of view on it is that there are some people who lie want to protect others’ feelings whereas some people lie to protect their own feelings because of some fear and insecurity in them. It depends on the situation they are in.