An analytical approach to the unified solution of kinetic equations in the rarefied gas dynamics. II. Heat transfer problems