Median apartment prices in Manhattan set a record in 2016, but by other measures it was a tough year for residential real estate.

Even as the median price of an apartment rose 9% this year, brokers said, the luxury market slumped. Fewer overall sales closed, and even fewer new contracts were signed.

Overall sales declined, with significant...