Nonlinear viscoelastic modeling of foams