Using code Lcode the mechanisms of defocusing of electron bunches at wakefield excitation in plasma have been demonstrated.