The end of the stud with the threads, if there is enough room you can double nut it. Put two nuts on the threads and tighten them against each other. Make them tight enough that the single nut on the other end will brake loose before the double nuts. Then breaks the double nuts loose from each other, and screw them off. Clear as mud, hope I explained it well enough.
Or just take the stud with the nut and just screw it back in like it was a bolt to hold the starter back on.