Illegal formation will get a 20% possession regardless of anything else. Out of position players give you a slight possession loss (from other forum members research, they assumed minimal loss of around 2%) and will have generally worse ratings. Part of formations being legal include GKs being used as GKs, so a formation could look fine but actually there is an outfield player as goalie and that makes it illegal