No, you cannot buy a city in the United States. A city is a municipal corporation—a political subdivision of a state—created by state charter or constitution. It possesses governmental powers (taxation, police, zoning, eminent domain) and holds public assets in trust for its residents. These attributes are not transferable to private ownership.
What can be purchased are the individual parcels of land, buildings, and businesses within a city's boundaries. In theory, a single entity could acquire a controlling interest in the private real estate of a small town, but the municipal government, its legal authority, and its public infrastructure remain public institutions. The closest historical analogues are "company towns" (e.g., Pullman, Illinois; Hershey, Pennsylvania), where a single employer owned most housing and commercial property—but even these were incorporated municipalities subject to state law.