Decomposition of Lie group into factors when one is not simply connected? As far as I am aware, for a group to be the direct product of groups it is sufficient that $G\cong H\times K$ as a set and $H$ and $K$ are normal in $G$. For Lie groups, normal groups corresspond to ideals of the Lie algebra. For $G$ compact, given an ideal $\mathfrak{h} \subset \mathfrak{g}$, we can always find a complementary ideal $\mathfrak{k}$ such that $\mathfrak{g}\cong\mathfrak{k}\oplus\mathfrak{h}$ by using an appropriate inner product, however, in order for the the group to be a direct product proofs require that $G$ be simply connected. As it seems we can get the product structure on $G$ from using the fact that $exp$ is surjective, I am not sure where the requirement for $G$ to be simply connected comes in... Additionally, if $G$ is not simply connected, is there a condition one can add to ensure the group is still a direct product?
 A: First, your original supposition is wrong:  If we let $G = \mathbb{Z}_4$ and $H = K = \mathbb{Z}_2$, then $G\cong H\times K$ as sets (since both are $4$ element sets), but $G$ is not a non-trivial direct product.
In the Lie group setting, it makes more sense to ask that $G\cong H\times K$ as smooth manifolds.  There are still counterexamples:
Let $G' = S^1\times SU(2n)$ and $G = G'/\pm(1,I)$. We let $H$ be the image of the $S^1$ factor in $G'$ in $G$, and $K$ be the image of the $SU(2n)$ factor.
Because $H$ and $K$ are images of normal subgroups under a surjective map, they are normal subgroups of $G$.  Further, we claim that $G$ is diffeomorphic to $H\times K$.
To make this diffeomorphism, we first let $\phi:S^1\rightarrow SU(2n)$ be given by $\phi(z) = \operatorname{diag}(z,z,z...,z, \overline{z}, \overline{z},...,\overline{z})$, where there are $n$ copies of $z$ and $\overline{z}$.  Then $\phi$ is a homomorphism, embedding $S^1$ into $SU(2n)$.
Now, let $f:G'\rightarrow H\times K$ be given by $f([z,A]) = (z^2, \phi(z)A)$.
This is well defined:  $f([-z,-A]) = (z^2, \phi(z)A) = f([z,A])$.
This is injective:  if $(z^2, zA) = (w^2, wB)$, then $z^2 = w^2$ which forces $z = \pm w$.  If $z = w$, clearly $A=B$.  If $z = -w$, clearly $A = -B$, so $(w,B) = -(z,A)$, so $[w,B] = [z,A]$.
This is surjective:  Given $(w,B)\in H\times K$, let $z$ be any square root of $w$.  Then $f([z, \phi(z^{-1})B]) = (w,B)$.
This is smooth:  If one precomposes with the map $G'\rightarrow G\rightarrow H\times K$, one gets the map $(z,A)\mapsto (z^2, zA)$, which is obviously smooth.  Since $G'\rightarrow G$ is a submersion, $f$ must be smooth as well.
The inverse is smooth:  At a point $(w,B)\in H\times K$, we pick a square root of $w$ and call it $z$.  Then, locally, the inverse of $f$ at $(w,B)$ looks like $([\sqrt{w}, \sqrt{w}^{-1} B])$.  Since the square root function, viewed as a map $\mathbb{C}\setminus\{0\}\rightarrow \mathbb{C}$ is locally smooth (if we keep picking the same branch), this is smooth.
As far as your intuition regarding $\exp$, the issue is that we could have $\exp(h) = \exp(k)\neq e$ for some $h\in \mathfrak{h}\subseteq \mathfrak{g}$ and $k\in\mathfrak{k}\subseteq \mathfrak{g}$.  For the $G$ example above, the vector $h = \pi \in \mathfrak{h}\oplus\mathfrak{k}$ and $k = \pi I$ exponentiate to $(-1, I)$ and $(1,-I)$ in $H\times K$.  But in $G$, these get identified to the same (non-identity) point.
Finally, to answer your last question:

Suppose $G$ is any compact Lie group for which $Z(G) = \{e\}$, i.e., $G$ is centerless.  If $\mathfrak{g} = \mathfrak{h}\oplus\mathfrak{k}$ with both $\mathfrak{h}$ and $\mathfrak{k}$ ideals, then $G$ is a direct product.

(So, for example, $SO(4)/\pm I$ must be a direct product, and indeed, it is $SO(3)\times SO(3)$.)
Proof:  Let $\pi: G'\rightarrow G $ denote the universal cover of $G$.  Using the group theoretic fact that $\pi(Z(G'))\subseteq Z(G) = \{e\}$, it follows that $Z(G')\subseteq \ker \pi$.  The reverse inclusion $\ker \pi \subseteq Z(G')$ is always true for the universal cover (see this answer by Jack Lee and the references he gives).  Thus, $Z(G') = \ker \pi$.  Of course, writing $G' = H\times K$ (where $H$ and $K$ are the unique simply connected groups with Lie algebras $\mathfrak{h}$ and $\mathfrak{k}$), it follows that $Z(G') = Z(H)\times Z(K)$.
Then $G = G'/\ker \pi = (H\times K)/(Z(H)\times Z(K)) = (H/Z(H)) \times (K/Z(K))$ is a direct product, as claimed. $\square$
Edit  Your claim in the comment is correct:

Theorem  Assume $G$ is a connected compact Lie group with Lie algebra $\mathfrak{g}$, which decomposes as a sum of two ideals $\mathfrak{h}\oplus \mathfrak{k}$.  Assume further that $H:=\exp(\mathfrak{h})$ and $K:=\exp(\mathfrak{k})$ intersect only at $e\in G$.  Then $G$ is Lie isomorphic to $H\times K$.

Proof:  Consider $f:H\times K\rightarrow G$ given by $f(h,k) = hk$.  This is clearly smooth because the multiplication in $G$ is smooth.  This map induces an isomorphism on the Lie algebra level, so it follows from general Lie theory that $f$ is a covering.
However,  $f$ is injective:  if $f(h,k) = e$, then $hk = e$, so $h = k^{-1} \in H\cap K =\{e\}$.  An injective covering map is a diffeomorphism, so we are done.
