Bike shifts well for low gears OR high gears - but not both
When gears shift cleanly only over part of the cassette, it's often due to the alignment of the rear gears.  If you look directly at the position of the cassette gears and jockey wheels as you shift up-and-down, is the angle not-quite-right when the chain won't shift properly?

Even with a new hanger, if the gear mech itself or the extender has been bent, you might need to bend the hanger out of shape to compensate.  You can buy a hanger alignment tool if necessary (about £65, so not cheap).

Also... is it the smaller gears that aren't shifting?  Is there enough tension in the chain?  If you've bought a new chain, be aware that most are supplied with several extra links that you need to remove with a chain-splitting tool (which costs less than a tenner).

Otherwise, any kinks in the gear cable or grit/gunk in the cable housing could be affecting the cable tension.  It's worth replacing them periodically, and it's both cheap and easy to do.  You'd probably want to buy a good quality pair of cable cutters, though (£15+).

Hope this helps :-)