Boundary conditions in theory of photothermal processes in solids