A New York City man has been charged in the deaths of four people, including a toddler, who died after a fire broke out in a residential building last month.