Health Secretary Matt Hancock says families should be able to visit relatives dying with coronavirus in care homes "wherever possible".