It's not an illegal formation.

A 3-1-4-2 & 4-4-2 will give the team some problems