I tried the most ubiquitous taught way. Bundle two heads together {HH}. Now, we have H,{HH},T,T. We have $\frac{4!}{2!}$ combinations if we consider H and {HH} distinct. So in the previous calculation H{HH}TT and {HH}HTT are both counted (and considered different). Basically 3 consecutive heads are counted twice. To arrive at the correct answer, I subtract the cases when 3 heads are consecutive. The final answer will be
$ \frac{4!}{2!}-\frac{3!}{2!} = 9 $
I wanted to ask if there is a general way to solve such problems. For example, the problem would be much difficult if we had 10 heads and 5 tails, and we want to enumerate the items in which there are at least 3 consecutive heads.