The following is an answer to a previous version of the question, which asked whether there exists an algebraic subgroup $H$ of $G$ such that $H(K)=H_1(K)H_2(K)$:
There are two necessary conditions on $H_1, H_2$:
First, the set $\Gamma:=H_1(K)H_2(K)$ has to be a subgroup of $G(K)$.
Also, since any algebraic subgroup of an algebraic group over a field is closed, the set $\Gamma$ has to closed in $G$.
These conditions are also sufficient. This follows from from the following fact: Let $K$ be a field and $\Gamma$ a subgroup of $\operatorname{GL}_n(K)$ which is closed (for the Zariski toplogy on $\operatorname{GL}_n(K)$). Then there exists an algebraic subgroup $G$ of $\operatorname{GL}_n$ such that $G(K)=\Gamma$. This is (part of) Theorem 4.8 of these notes of Milne: http://www.jmilne.org/math/CourseNotes/aag.html