The answer is yes, as pointed out by Derek Holt in a comment:
Let $H:= \phi^{-1}(H_1 \times H_2)$, and let $\phi_1, \phi_2$ denote the components of $\phi$.
By Kurosh Subgroup Theorem, $H$ may be written:
$$
H = F(X) * (*_i u_iK_{1,i}u_i^{-1}) * (*_j w_jK_{2,j}w_j^{-1})
$$
for a number of subgroups $K_{1,i}$ of $G_1$ and $K_{2,j}$ of $G_2$, a subset $X$ of $G_1 * G_2$ and words $u_i,w_j$ of $G_1*G_2$.
If $H$ were not free, then some of the $K_{1,i}, K_{2,j}$ would not be free, say $K:=K_{1,i}$; assume this is the case.
By construction, $u_iKu_i^{-1}$ is then a non-free subgroup of $H$, and
$$
\phi_1(u_iKu_i^{-1}) = \phi_1(u_i)\phi_1(K)\phi_1(u_i)^{-1}
$$
is a subgroup of $H_1$, conjugate to $\phi_1(K)$.
On $G_1$, viewed as a subgroup of $G_1*G_2$, $\phi_1$ is injective, so that $\phi_1(K) \cong K$ is not free, and $\phi_1(u_i)\phi_1(K)\phi_1(u_i)^{-1}$ isn't either.
Since $H_1$ contains a non-free subgroup, it can't be free, and we have reached a contradiction.