The first thing that's done by HMRC (or, more accurately by their agents, Parcelforce Worldwide, who have the contract for assessing routine import charges) is to decide upon the value of the item being imported. (As Woofgang points out, that's not necessarily the same as the actual price paid for an item). They've decided that your ukulele is worth £544.
Then they calculate the Customs Duty to be paid. The rates vary enormously, depending upon the type of goods you're importing. (If you'd made the mistake of importing cotton-based clothing from the USA, you'd have got hit for 12% as the regular duty, plus a further 15% because the USA breaches WTO rules by subsidising their cotton farmers), The rate to be paid on stringed musical instruments is quite low, at just 3.2%. That's where the £17.41 comes from.
Then they work out the VAT to be paid. VAT is charged at 20% of the TOTAL value of the instrument, INCLUDING the Customs Duty to be paid on it. (Yes, that is a tax on a tax!). So they add £544 and £17.41 together, to get £561.41. Then they calculate 20% of that, which is where the £112.28 comes from.
Then Parcelforce Worldwide want paying for doing their sums, contacting you and collecting the charges on behalf of HMRC. HMRC don't pay them directly for their services but they have agreed that Parcelforce Worldwide can charge a flat rate of £12 for parcels with a value of less than £873. (The charge goes up to £25 for higher value parcels).
It's all perfectly normal and, in many ways, reasonable. (HM Government clearly don't want people to be able to avoid paying VAT just by buying from abroad. To permit that to happen would harm the economy and also harm the interests of the British businesses who would be losing trade).
At the moment you only get clobbered for such charges when you're importing from a non-Eu country. After Brexit you'll have to pay them when importing goods from EU countries as well.