Re-edited in view of Derek Holt's comment : Some suggested directions- not a complete answer : Suppose we have $N \lhd G$ with $N \leq H_{1} \cap H_{2},$ and that there is an isomorphism $\alpha : H_{1} \to H_{2}$ which leaves $N$ invariant. Then $\alpha$ induces a well-defined isomorphism from $H_{1}/N$ to $H_{2}/N,$ and we may pass to $G/N.$ Hence we assume that there is no non-trivial choice of such an $N$ possible.
Let $[G:H_{1}] = p^{a}$ for some prime $p$ and integer $a.$ We note the general fact that if $M$ is a subgroup of the finite group $G,$ and $[G:M]$ is a power of $p,$ then $O_{p}(M) \leq O_{p}(G).$ It suffices to prove that $O_{p}(M) \leq P$ whenever $P \in {\rm Syl}_{p}(G).$ But $|PM| = \frac{|P||M|}{|P \cap M|}$, and this is divisible both by $|G|_{p^{\prime}}$ and by $|P|,$ so that $PM = G$ and $P \cap M \in {\rm Syl}_{p}(M)$. Hence $O_{p}(M) \leq P \cap M,$ as claimed. Hence we have $O_{p}(H_{i}) \leq O_{p}(G)$ for each $i.$ Note that $|O_{p}(H_{1})| = |O_{p}(H_{2})|.$ Suppose that $O_{p}(G) \leq H_{1}.$ Then $O_{p}(H_{2}) \leq O_{p}(G) \leq O_{p}(H_{1}) \leq O_{p}(G) $ and $O_{p}(H_{1}) = O_{p}(H_{2}) = O_{p}(G),$ which is then invariant under any isomorphism from $H_{1}$ to $H_{2}.$ Our assumptions then imply that $O_{p}(G) = 1.$ (Likewise, we can't have $O_{p}(G) \leq H_{2}$ if $O_{p}(G) \neq 1$- the maximality of $H_{1}$ is not essential in the preceding argument). Hence, if $O_{p}(G) \neq 1,$ then $G = O_{p}(G)H_{1}$ and $$|G| = \frac{|O_{p}(G)||H_{1}|}{|O_{p}(H_{1})|} = \frac{|O_{p}(G)||H_{2}|}{|O_{p}(H_{2})|},$$ so $G= O_{p}(G)H_{2}.$
Comments on the case $O_{p}(G) = 1$ : In this case, we now know that $O_{p}(H_{i}) = 1$ for each $i.$ Notice that $H_{1}$ and $H_{2}$ each contain a Hall $p^{\prime}$-subgroup of $G,$ and we may suppose that $H_{1}$ and $H_{2}$ have a common Hall $p^{\prime}$-subgroup, say $X$, possibly after replacing $H_{2}$ by a conjugate. We again may suppose that no non-trivial normal subgroup of $G$ which is contained in $H_{1} \cap H_{2}$ is invariant under any isomorphism from $H_{1}$ to $H_{2}.$ It follows that $O_{p^{\prime}}(H_{i})$ strictly contains $O_{p^{\prime}}(G)$ for each $i$ and that $F(H_{i})$ strictly contains $F(G)$ for each $i$ (in fact, the latter works prime by prime for $O_{q}(H_{i})$ for each $i ).$
Note that $F(H_{1})F(H_{2}) \leq F(X),$ so that $F(H_{1})F(H_{2})$ is, in particular, nilpotent.
Let $q$ be a prime for which $O_{q}(G)$ is non trivial. Then $O_{q}(H_{1}) > O_{q}(G)$ and $O_{q}(H_{1}) \leq X \leq H_{2}.$ Set $U = O_{q}(H_{1}).$ Then $H_{1} = N_{G}(U)$ as $U\not \lhd G$ and $H_{1}$ is maximal.
Now $$O_{q^{\prime}}(H_{1} \cap H_{2}) = O_{q^{\prime}}(N_{H_{2}}(U)) \leq O_{q^{\prime}}(H_{2}).$$
We claim that $O_{q^{\prime}}(H_{1})$ must have order divisible by $p$ if it is non-trivial. For otherwise, $ O_{q^{\prime}}(H_{1}) \leq X \leq H_{1} \cap H_{2}$ and $O_{q^{\prime}}(H_{1}) \leq O_{q^{\prime}}(H_{1} \cap H_{2}) \leq O_{q^{\prime}}(H_{2}),$ so $O_{q^{\prime}}(H_{1}) = O_{q^{\prime}}(H_{2}).$ But then $O_{q^{\prime}}(F(H_{1})) = O_{q^{\prime}}(F(H_{2}))$ and these are both non-trivial, a possibility we have excluded, as it leads to $H_{2} \leq H_{1}.$ This leaves two possibilities to consider. Firstly, it may be that $F(H_{1})$ is a $q$-group for some prime $q$. In that case, $F(G)$ is a $q$-group. We claim that $q<5$ in this case: for otherwise, for $Q \in {\rm Syl}_{q}(X),$ we have $ZJ(Q) \lhd G,$ and $ZJ(Q)$ is a normal subgroup of $G$ which is invariant under any isomorphism from $H_{1}$ to $H_{2}$.
The other possibility is that whenever $O_{q}(G) \neq 1$, $O_{q^{\prime}}(H_{1})$ has order divisible by $p,$ in which case, $O_{q^{\prime}}(G)$ must have order divisible by $p,$ as $O_{q^{\prime}}(H_{1}) \leq O_{q^{\prime}}(G).$