The term "town" has a different meaning in New York State than in most other states.
Here's a NYS Geographic Glossary with the NYS definitions of county, city, town, village, hamlet and postal zone.
.....Cities, Towns, Villages, Hamlets and Postal Zones in New York State
New York State is divided into counties.
County A county is a municipal corporation, a subdivision of the state, created to perform state functions; a "regional" government All counties are divided into cities, towns and Indian reservations.
City A city is a unique governmental entity with its own special charter. Cities are not sub-divided, except into neighborhoods which are informal geographic areas.
Town A town is a municipal corporation and encompasses all territory within the state except that within cities or Indian reservations. Towns can be sub-divided into villages and hamlets.
Village A village is a general purpose municipal corporation formed voluntarily by the residents of an area in one or more towns to provide themselves with municipal services. The pattern of village organization is similar to those of a city. A village is divided into neighborhoods, which are informal geographic areas.
Hamlet A hamlet is an unincorporated area in one or more towns that is governed at-large by the town(s) it is in. A hamlet is divided into neighborhoods, which are informal geographic areas.
Postal Zone "City" and "Town" A postal zone "City" and "Town" is an administrative district established by the U.S. Postal Service to deliver the mail. Postal zone "City" and "Town" may not (but are encouraged to) conform to municipal or community borders. Thus, postal zone location does not always determine city, village or hamlet location.
Please be aware: In many areas of New York State, the problem of non-conforming postal zones leads to a situation where the majority of places have a different community name in their mailing address than the community where that place is actually located.