Metaphor
A metaphor is a direct comparison to two seemingly unlike things that, nevertheless, share a common property. In this example, the doctor who created tar water is being compared to a medical beast. An apt comparison considering its use by Pip's beastly sister as a punishment.