Magnetoelastic coupling influence on the magnetocaloric effect in ferromagnetic materials