Please note, that I'm new to Spring as well, and therefore this could be incorrect.
Presumably, looking at the code the following happens:
1) A get request is made to /rides
2) The method getRides() is called which returns a list of Ride objects
3) Spring finds a template file, named rides.jsp and injects the data into that file then sends that page to the client/web browser.
Step 3 is the "magic" step. As long as you have the
JSP file (View) in the correct location Spring will read that file and combine the data from the Model as specified by the Controller.
We don't really have to know how Spring finds the file, as many things are setup by convention over configuration.
There are different template engines out there which can be quickly changed out in Spring and each one handles the data slightly differently.