A county is a municipal corporation comprising the inhabitants within its boundaries and formed for the purpose of exercising such powers and discharging such duties of local government and administration of public affairs as may be imposed or conferred upon it by law.
N.Y. CountyLaw § 3