Without the series resistor you would overload the pin and pull it well below
5V. The series resistor takes up the difference between led voltage and 5V and
so long as you don't pull too much current from the pin it will be fine.
Your circuit shows the motor power going through the voltage regulator - that's
not a good idea - have the motor supply direct from the battery.