The sentence would be correct and mean the exact same thing with a subject, but that subject would then be the singular impersonal il:
Il ne lui restait que quelques touffes de poils éparses sur le crâne.
In the original sentence, the actual subject is Que quelques touffes de poils, as the plural restaient shows:
Seules quelques touffes de poils éparses lui restaient sur le crane.
Lui represents Denise. Without this pronoun, the sentence would have been slightly odd:
Ne restaient que quelques touffes de poils sur le crane.
It is not incorrect but it somewhat gives the impression that the hairs had the choice to leave but a few of them decided to stay.
Note also that the author, to reinforce the image and the surprise it inspires, deliberately uses the wrong word for hair, poils, while cheveux would be expected on a scalp.