A subcontractor is someone who agrees to perform part of a larger job. If you've been hired to renovate a house but you're not an expert plumber, you could hire a subcontractor to install new pipes.
If you were building a new house, you might hire a contractor to do the job. While the contractor would be responsible for the entire project, she might pay subcontractors to do specific tasks, like digging the foundation, installing windows, or wiring the new house for electricity. You would pay the contractor for the whole project, and she would pay the subcontractors for the work they performed.