I know that I should say"
He/She/It has something,
and
I/We/You/They have something.
I get confused with sentences such as:
he was having a good time
he is having a good time
In these two sentences, why do we use a variation of have instead of a variation of has?