What is the purpose of the 5V pin on the arduino?

See the attachment for the project I reference in this post I recently got an Arduino Uno as part of the Vilros Ultimate Starter Kit. It came with a guide that shows you how to do many different beginner projects but doesn’t answer every question I end up having along the way. One thing I am confused about is the functionality of the 5V pin on the Arduino. For all of the projects in the guide I have done so far, it has me connect a wire from the 5V pin to the positive power rail on the breadboard. I assumed this supplied the power for the LEDs on the breadboard until I discovered that, upon removing that connection from the 5V pin to the breadboard, the LEDs still remain lit. So it seems to me that the power for the LEDs comes from the digital pins that are also connected to the breadboard. Can anyone help me understand this and, if you are feeling extra generous, give me a basic run down of the flow of power through the project I attached in the post. Thank you!

In the case of the project in your picture, the 5V pin it's not necessary. The person how writes the manual, may attach this connection for education purpose only. I believe that this is one of the very first projects and the idea is that "the student" get used to always connect the the 5V to the "+" rail of the breadboard and the GND to the "-" rail.

The power (or current) leaves the Arduino board through the digital outputs 2 to 9 it passes through the LED form the + to the - pins, then passes through the resistor and then through the "-" rail of the breadboard to the GND pin of the Arduino board.

Okay thanks! The only other question I have is regarding the resistors. You say that the current flows through the LED then the resistor? I thought the purpose of the resistor was to reduce the current so that the LED doesn't burn out. So shouldn't the resistor be placed so that the current flows through it before flowing through the LED?

Current is the same at every point in a series circuit. If you have a pipe and place a restriction, the water coming out of the spout is the same no matter where in the pipe the restriction is placed.

Oh okay, that makes sense. Thanks!