It can be done using several methods,and if you plan on doing it regularly esp on cues you've never seen before,you really need SEVERAL tools to do it right.
A QUALITY pair of small adjustable pliers like Knipex Cobras,or Channel-Lock.
My Knipex have a set of removeable guards on them so they can be used for normal things like the tailstock clamping nut on my lathe,or more importantly to the subject at hand,can be used with 1/4 thick rubber pads for grip for removing the ferrule,or screwing it on,which may need to be done REPEATEDLY if you prefer to fine-tune your fit.
A "flexible" measuring instrument you trust,meaning you can use it several ways.
You'll need to measure the tenon length,which CAN be done with a ruler,and wouldn't matter in a situation where the tenon is unthreaded and uncapped,because you can always face it off.
In a slightly more complicated scenario,you want to use a capped but unthreaded ferrule,you'll need to measure how deep your drilled hole is,and to go another step you'll REALLY need to measure the depth of a hole that is TAPPED.
This can be done with the rod on the back of most calipers,a depth mic,or if you can find one narrow enough,a ruler once again.
A 0-1" mic,preferably vernier or digital.
The most common thread size used for this is 5/16-18. You'll need a 3 piece set of these taps,plug,taper,and bottoming. I've added a 4th to mine,a modded bottoming tap ground flat on the end.
I have an old,cracked ivory ferrule that I use as a testing standard. You can make one of these yourself,or just buy a pre-tapped blank.
For this thread specifically,you"ll need an F drill bit which is .257,and also a true 1/4 drill bit. If you have to thread the tenon using one of the compression dies,you'll start with a .280 diameter or so. Using the 1/4 drill gives you a little wiggle room to tighten up the thread fit,the F drill has been the universal drill bit for a 5/16-18 for close to 100 years.
Having to fabricate the ferrule to something out of the norm will also require other sized drill bits,or a boring bar small enough to go into a 1/4 inch hole,and maybe up to 1 1/4" deep.
You'll also at some point need both metric and standard thread pitch gages so you can figure out how to re-attach the new ferrule,which you will have to fabricate.
A good small file,for shaping the end of the tenon so it fits as close to the same shape of the bottom of the hole you drilled,so there is almost NO gap between the end of the tenon and the bottom of the hole,and if there is,a small enough gap that it can be filled with glue so completely that even if it gets got,the glue doesn't break down and start rattling inside.
This can also be done with your regular,or a specific lathe cutter as well.
GOOD glues,and several kinds.
You'll need a wood glue,a slow and a fast setting epoxy,along with CA glue.
CA glues can be used to lock a ferrule down while the epoxy in setting inside,it can be used to harden and build up the tenon for compression threading,and the wood glue and both epoxy types can be used for various materials and to solve issues with fitting.
Extra maple,for tenons,in case it was already broken or it comes apart while removing the ferrule. You can use old,scrapped shaft wood,buy pre-cut dowels,or a whole dowel rod.
Then you have to add a wide range of different materials,to satisfy customer demands on playability,cost,moral/ethical issues with ivory,as well as to improve on what it came with,or keeping what it came with as close as possible to identical to original,if not identical.
All this without going into stuff like having to use dental picks for digging trash out of threads,etc.
I'll quit flexing my knowledge muscle now