Number of possible states on a $6\times 6$ grid
By considering the case of a $2 \times 2$ grid with $1$ black piece and $1$ white piece for each row and each column you can count $2$ ways (i.e. BW-WB and WB-BW). It is not too difficult to count patiently all cases for a $4 \times 4$ grid, totalling $90$ ways.
Searching OEIS with $2,90$, you can find OEIS sequence A058527 and, for the $6 \times 6$ grid the value $297200$.