Olshanskii showed that for $p>10^{75}$, there are continuumly many nonisomorphic Tarski monsters. These are countably infinite groups whose proper nontrivial subgroups are cyclic of order $p$.
On any group $\Gamma$ one can define an equivalence relation $E_{\Gamma}$ which relates two elements if they generate the same subgroup.
If $\Gamma$ is a Tarski monster for prime $p$, then $E_{\Gamma}$ has one singleton class $\{e_{\Gamma}\}$ and countably many other classes of size $p-1$. The proper nontrivial subgroups of $\Gamma$ are exactly those subsets of $\Gamma$ that are unions of the singleton $E_{\Gamma}$-class and a nonsingleton $E_{\Gamma}$-class.
Choose $G$ and $H$ to be nonisomorphic Tarski monsters for the same prime $p$. There is a subgroup-preserving bijection $\varphi:G\to H$. To see this, start with a bijection $\varphi:T_G\to T_H$ from an $E_G$-transversal $T_G$ to an $E_H$-transversal $T_H$ which maps $e_G$ to $e_H$, then extend it to all of $G$ in such a way that $\varphi(t^k)=\varphi(t)^k$ for $t\in T_G$, $k\in \{1,2, \ldots,p-1\}$. This function $\varphi$ is a bijection from $G$ to $H$ that has the property that its restriction to any proper subgroup of $G$ is a homomorphism.
For this $\varphi$, the desired property holds in the following strong form: For every $g\in G\setminus\{e_G\}$ there are maximal subgroups $M_g \subseteq G\setminus \{g\}$ and $N_g \subseteq H\setminus \{\varphi(g)\}$ such that $\varphi\colon M_g \to N_g$ is an isomorphism.