Two-dimensional frustrated Ising model with four phases