The rear sprockets you just need to swap for your actual unit, taking off your old wheel and putting on the new. If you have a cassette, then get a hubmotor that supports that. If yours is a thread-on type, then get that kind of motor. Etc. If you can't, and can't get the right kind for the new wheel, then you may need to change your shifter and derailer out for one that will work with whatever you can put on the wheel.
To help you solve some of your issues, along with others you probably haven't even thought of yet, I'd recommend doing as much reading of various other builds with similar needs / problems as you have time for.
You may also want to go to
https://www.ebikes.ca/tools/simulator.html
and read the entire page to learn what everything is and how to use it, then play with different setups and situations to see how they perform, so you can be sure that what you want to do will work with the stuff you already have or what you plan to get.
But here's some things to think about:
35MPH+ is likely to take upwards of 50-60wh/mile to sustain, on flat ground with no winds. So to go 25miles+ you'd need at least 25 times that, so say 25 * 60 = 1500wh. That's a fairly large battery, especially if you have space constraints. It might mean having to carry two paralleled batteries to get the range you want. I have a 2000wh battery that is around 35lbs, so you're probably looking at 25lbs+ of battery, depending on type.
Now...batteries lose capacity (and range) over time, and also sometimes you run into detours or headwinds/etc that can significantly impact your needed range/capacity. So it's a good idea to add 20%+ to your known needs to allow for these things. So you might need at least 2kwh.
Since you have lots of hills, it's going to take more (possibly a lot more) capacity to do what you want. It may take a lot more power to do it, too, so you may need a bigger motor to maintain 35MPH+ up those hills, and this may mean an even bigger battery to handle the extra power to give the same range.
For instance, if you have a 10% grade hill, and something like the H3548 motor and a 40A controller at 72v, it would take about 2kw to just maintain about 28mph (fastest that could do on a hill lke that). The power usage goes up to about 100wh/mile, and will overheat the motor in about 5 minutes.
https://www.ebikes.ca/tools/simulator.html?batt=B7223_AC&cont=C40&axis=mph&autothrot=true&throt=100&hp=0&grade=10
Let's assume that half your route is going up such hills, then your average wh/mile goes up; divide both the wh/mile numbers by two and add them, you get about 80wh/mile average. So you would need at least 25 * 80, or 2000wh, which if you add a good margin to is now up to 2500wh. So now you have about 40lbs of battery on the bike.
You may also need a bigger motor to handle the power without overheating, especially if you need to maintain 35mph up those hills, becuase you'll need a bigger controller to do that, too (which will then also increase your power usage, which means needing an even bigger battery, etc).
So...at some point you end up with something as big and heavy as a small motorcycle, but with a frame that can't handle that weight, and wasnt' designed for those speeds either in it's wheels or it's brakes, suspension, etc.
At that point, you're better off actually getting a motorcycle, that's designed to do what you want.