If the current in a series circuit remains the same, then what is the use of a resistor? I read somewhere that as electrons flow through a circuit, they are accelerated towards the positive terminal, but in collision with other electrons and fixed positive ions, they lose their kinetic energy and so their speed remains the same as they exit the resistors.
This gave me an answer as to why the current in a circuit remains the same, but made me think that if the current is the same, what is the use of the resistors? Do resistors of greater resistances cause the electrons to collide more among themselves and lose more kinetic energy, causing the wire to heat up? If this is the case, then shouldn't the speed of the electrons decrease with higher value of resistances?
(While answering the questions, please bear in mind that I am a tenth grade student who has just been introduced to current, emf, etc. please correct me if I have made any mistake in the body of my question)