Colored graph with $2$ colors

The answer is YES and the above comments give several references for this result called the "lamp lighting problem". Below there is a direct proof.

Let $G$ be a graph with vertices $v_1,v_2,\dots, v_n$ and let $A$ be a matrix such that $a_{ij}=1$ if and only if $i=j$ or there is an edge between $v_i$ and $v_j$.

Assume that the vertices of $G$ are all blue (colour $0$). It is possible to change their colour to red (colour $1$) by using the those moves if and only if there is a vector $y=(y_1,\dots y_n)^t\in \mathbb{Z}_2^n$ such that $$Ay=u$$ where $u=(1,1,\dots,1)^t$, that is, since the matrix $A$ is symmetric, if and only if $$u\in \text{Im}(A)=\text{Im}(A^t)=(\text{Ker}(A))^{\perp}.$$ Thus it suffices to show that $Ax=0$ implies $u\cdot x=0$: $$\begin{align} 0&=\sum_{i=1}^n(Ax)_i=\sum_{i=1}^nx_i+\sum_{i=1}^n\sum_{j\not=i}a_{ij}x_j\\ &=u\cdot x+2\sum_{1\leq i<j\leq n}a_{ij}x_j= u\cdot x \pmod{2}. \end{align}$$ and we are done.


Yes, it can be done for any graph. This is a much-discussed problem called the "lamp lighter's problem" or the "all ones problem" or "lights out". This paper which is available online looks like a good survey:
Rudolf Fleischer and Jiajin Yu, A Survey of the Game "Lights Out".