Solar panels are being installed in schools to save energy and teach lessons about cutting carbon emissions.