I'll likely buy a handle but for the sake of asking, would shaping a wooden baseball bat into a handle work even if baseball bat is of unknown wood? I wouldnt know if any baseball bats are soft wood
No functional baseball bats are made of softwoods.
In the wood trade softwood has nothing to do with the actual hardness/softness of the wood. It is a traditional trade term for a wood from a conifer tree (pine, spruce, larch, redwood, cedar, juniper, yew etc.):
https://en.wikipedia.org/wiki/Softwood
Hardwoods are not necessarily harder than softwoods: think for example of balsa wood, which is technically a hardwood.
There is a reason why axe handles are made of some types of hardwood rather than softwood: the fiber structure of softwoods make them more brittle, less resistant to the violent shocks handles are exposed to.
Not all hardwoods are useful for that use either: a wood can be very hard and brittle in the same time.
There is a certain combination of hardness, stiffness, elasticity and other mechanical properties which makes some types of wood useable for striking tool handles.
In North America hickory and ash are widely available and are the most commonly used woods for axe and hatchet handles, because they are on average more shock-resistant and are considered to transmit less shock to the hand than other woods.
When buying or making a handle, please take the time and read up on the properties of a good wooden handle: straight grain, i.e. no grain run-off is essential.
I personally would also suggest you buy a hickory handle from the sources SC T100 mentioned.
Todays baseball bats are made mostly of some type of maple - generally weaker woods than that of the average hickory handles.
There are also some ash baseball bats available on the market. Ash wood (depending on the species) is generally better suited for hatchet handles than the wood from the various maple species.
I still think that hickory is the way to go.
Good luck and please let us know what was your choice & how did it work out for you.