This question arose in the context of this problem:
Let $G$ and $G'$ be groups and $V$ a subgroup of $G\times G'$. Do there exist subgroups $H \leq G$ and $H'\leq G'$ such that $V \cong H\times H'$?
In the case that the answer is "no": Are there any reasonable constraints to $G$ and $G'$ such that the answer is "yes"? For finite abelian groups, the answer appears to be yes.
Clarification
My question is about the subgroup $V$ being isomorphic to a direct product of subgroups. This condition is strictly weaker than being equal to a direct product of subgroups: For the "equal" version, the classical counterexample is the diagonal subgroup $V = \langle (1,1)\rangle \leq G\times G$ where $G$ may be any group but the trivial one. However, this doesn't provide a counterexample to my question, since $V\cong G\times\{1\}$.