Effect of rare-earth ions on magnetic properties and spin excitations in manganites