As projects grow, putting everything in one file becomes unmanageable. Modules let you split code into separate files, each with a clear purpose.
Modules provide encapsulation. Each file has its own scope. You explicitly export what others can use and import what you need. This makes code easier to understand, test, and maintain.