New York, like many cities, wants to provide more housing and soak up empty office space. But the transition can be complex and costly.