Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
I somehow disagree. Life isn't always as beautiful as the homotopy type of a CW complex especially if one is not interested in algebraic topological questions for its own sake.
The corrections to the McDuff-Segal paper Peter May mentioned can be found as Lemma 3.1 in D.McDuff - "The homology of some groups of diffeomorphisms.".
Does one not even need finite dimensional cohomology and not just finitely generated? The result is usually proved by the classification of finite-dimensional, graded commutative, graded cocommutative Hopf algebra over a field of characteristic 0. A theorem of Hopf says that it is a free exterior algebra with generators of odd degree. Does it really suffice to have finitely generated cohomology?
As a supplement: More general is every $(k-1)$-connected compact manifold of dimension $\leq (4k-1)$ formal for $k>1$. The result mentioned by Sinan Yalin follows for $k=2$. To get a counterexample in dimension 7, one can (as an alternative to the mentioned papers) realize (via Sullivan-Barge-Realization) the minimal Sullivan algebra $(\bigwedge<v,w,x,y,z>,d)$ where $deg(v)=deg(w)=2$, $deg(x)=deg(y)=deg(z)=3$ and $d(v)=d(w)=0$, $d(x)=v^2$, $d(y)=vw$, $deg(z)=w^2$ as a compact simply connected 7-manifold. This result will be non-formal, since $<v,v,w>$ is a nontrivial Massey product.