Forfeiting is when you leave a match before it ends. This can happen if you voluntarily quit or your device disconnects.
If you forfeit, it is highly likely you will lose skill. However, the amount depends on several factors such as your current place in the match scores and who you are playing with (you will lose more against lower skilled players).
If all of your opponents forfeit in a matchmaking game, you will get credits and no energy will be deducted. In a friend match, this will not happen; you will lose energy but can still get credits.
If you happen to join a game with no players, you will not lose energy or skill, and instead be compensated with 40 credits.
This is good if you want the credits.