To thread a barrel you need a good lathe and a steady rest. use a 60 degree bit to cut the threads and make several passes. The thread pitch is 1.062" x 16 TPI. Shank length should be .700" plus the width of the recoil lug.
If you do not have experience on a lathe and especially cutting threads, take it to a gunsmith. It is not easy to do. If the barrel has sight cuts, the threads must be indexed so that the sights are at the top when the barrel is installed. The barrel must also be back bored for the bolt head, chambered and headspaced. I do not recommend anyone but an experienced gunsmith attempt to do this.
Hi, I concur with Tom. I would not recommend anyone trying this unless you have proper equipment and tooling AND you know how to use it, unless you are willing to scrap your barrel. Tom gave you basic guidelines to answer your question. The rest is learned from an experienced gunsmith. The old pay me now or pay me later thing is involved in this kind of project, kind of like the oil commercial and the mechanic. If you want a good rebarrel job, take it to a custom gunsmith who knows what he is doing. There are a lot of factors included in a project like this, like headspacing, fitting the threads, knowing how to index the barrel when in the lathe cutting the threads, just to name a few. Please give Tom the credit for this question, as I am only confirming what he said.