But federal tax changes under consideration in Congress could make microgrids more expensive for schools and localities that provide services during emergencies.