This is what I know, please tell me if I am wrong: An electron has an elementary charge (let’s call that charge e). A current is defined as the amount of e (elementary charge) that flows past a point in a circuit in one second. Now, why does the amount of current passing through a resistor decrease as its resistance increases? The electrons still have the same elementary charge after passing through the resistor right? Does that mean that the electrons move more slowly so that the amount of charge passing in one second decreased?
The situation you probably have in mind (as it is the most common) is that you apply constant voltage to your resistor, i.e., you have a voltage source. The voltage between two points (in this case, the two sides of your resistor) is proportional to the energy gained by a charge when moving from one point to the other. This energy is used to accelerate the electron. However, the electron is also slowed down when interacting with the resistor (which heats up the resistor).
The higher the resistance, the more intensively do the electrons interact with the resistor and the slower they are. Since electrons are repelling each other, this cannot be counteracted by more electrons going through the resistor.
You can compare this situation to two basins of water at different levels (voltages) connected by a thin tube with a sponge inside (the resistor). The less porous the sponge, the slower the water flow (the current).
Note that there also exist current sources, which produce a constant current. If a resistor is connected to such a current source, the voltage will increase such that the target current is reached. The higher the resistance, the higher the voltage (and the more heat is disposed into the resistor). In the water analogy, such a current source corresponds to a pump working at a fixed rate, no matter how much pressure is needed to pump the water.