This is the classic board game of Reversi or Othello. You play as either black or white, and the goal is to have the most pieces in your color when the game is over.
You turn the opponents pieces by placing yours on either side of his. That turns his over to be your color. Placed correctly you can turn whole lines (minus two pieces) from his to yours.