Spring is a framework which supports (among other things) dependency injection. Using Spring also makes it very easy to create web applications. Spring favors convention over configuration and was originally created as an alternative to Java EE (which was overly complex, verbose, and burdensome). But Spring is more than just dependency injection. It has core support for dependency injection, transaction management, web applications, data access, messaging, aspect-oriented programming, testing, and more.
Spring helps you by making it easy to inject dependencies, which reduces tight coupling between a class and specific implementations. For web applications, Spring follows the MVC (Model View Controller) pattern, and has specific annotations (and XML-based configuration) to help you write code that follows this pattern.
I suggest reading more about dependency injection, MVC, and the Spring framework in general to know more; there's far too much information to cover in just a single answer.