Group structure on Eilenberg-MacLane spaces
The standard classifying space functor $B$ from topological groups to topological spaces is product preserving, so it takes abelian topological groups to abelian topological groups. Start with an abelian group $G$ as a discrete topological group, so a $K(G,0)$. Apply the functor $B$ iteratively $n$ times to reach $B^nG$, which is an abelian topological group and a $K(G,n)$.
// This is essentially the same answer that Qiaochu Yuan deleted for some reason. Hence CW.
By the Dold-Thom theorem $\pi_\bullet(\mathbb Z[X])=H_\bullet(X)$, where $\mathbb Z[X]$ is the free abelian group generated by $X$. Note that $\mathbb Z[X]$ is never connected ($\pi_0(\mathbb Z[X])=H_0(X)\supset\mathbb Z$) but it has reduced version: (fix a point $x_0\in X$ and define) $\widetilde{\mathbb Z[X]}:=\mathbb Z[X]/\mathbb Z[x_0]$ — and $\pi_\bullet\widetilde{\mathbb Z[X]}=\tilde H_\bullet(X)$.
// Remark 1. Actually (for connected $X$, at least), $\widetilde{\mathbb Z[X]}$ is homotopy equivalent to the free abelian monoid generated by $X$ with $x_0$ as the unit (aka $Sym^\infty(X):=\operatorname{colim}_{+x_0}Sym^n(X)$) that is used in the formulation of the Dold-Thom theorem in, say, nLab.
Now, it's easy to construct a Moore space $M(G,n)$ s.t. $\tilde H_n(M(G,n))=G$ and all other (reduced) homology groups of $M(G,n)$ are zero. And by Dold-Thom theorem topological abelian group $\widetilde{\mathbb Z[M(G,n)]}$ has homotopy type $K(G,n)$.
// Remark 2. In particular, $\widetilde{\mathbb Z[S^2]}$ is a topological abelian group with homotopy type of $\mathbb CP^\infty$. (Looks more explicit to me than most answers on MO.)
Upd. It's even easier to use $\widetilde{G[S^n]}\cong K(G,n)$.
Reference: M. C. McCord, Classifying spaces and infinite symmetric products, Transactions of the American Mathematical Society 146 (1969), 273–298.
See def. in the strart of Sec. 5 ($B(G,X)$ is my $\widetilde {G[X]}$), Prop. 6.6 (if $G$ is abelian group, so is $B(G,X)$), Cor. 10.6 ($\widetilde{G[S^n]}$ is an abelian group of homotopy type $K(G,n)$), Thm 11.4 (Dold-Thom type theorem I use; stated for any based $X$ having homotopy type of CW complex).
Another way to find homotopy type of $\mathbb Z[X]$ is to observe that if $X$ is cofibrant (e.g is a CW complex), $|X^\Delta|\to X$ (where $X^\Delta$ is the simplicial set of singular simplices in $X$) is a homotopy equivalence, so $\mathbb Z[X]\cong |\mathbb Z[X^\Delta]|$; now, by Dold-Kan correspondence homotopy groups of $\mathbb Z[X^\Delta]$ coincide with homology group of the corresponding complex — which is exactly singular complex of $X$.
Well, an interval is a $K(\{e\},1)$, where $\{e\}$ is the trivial group, and an interval has no group structure that can make it a topological group (every continuous map has a fixed point). So there certainly are some $K(G,n)$'s out there that cannot be made into topological groups. Maybe if you refine the question there could be some sort of answer.