With those long stays in the back (I'm looking at how much space there is between the front of the back tire and the frame), and the sorta kinda conservative 67 degree head tube angle, this bike looks like its meant more for medium trails than hardcore stuff. As an aging cyclist myself, I can see the desire to buy something capable but only so for lesser things than you once rode.
measurements etc.:
Discover your next great ride with Powerfly FS 7 Plus. See the bike and visit your local Trek retailer. Shop now!
www.trekbikes.com
It may be you can fix this, but you have to be ready to throw money at parts and understand you might fail. You have to be comfortable swapping parts around on a bike, and familiar with working on them in general. If not then don't mess with it. Go to a bike shop and have them work with you on fitment.
Is your reach on this bike shorter than it was on another that you were comfy on? A longer stem could help, but again it may not so there's that 'might fail' thing. Myself, I have a half-dozen stems I can try out in my garage parts bins, but not everyone has that resource. Instead, for something like a stem experiment, try a cheap one for ten bucks that is good enough for a few mild rides. If the solution works get a proper quality part matching that spec.
The handlebars are 750mm wide. Go wider. On paper at least, on an mtb wider bars increase comfort, stability and steering leverage. Pay attention to the rake (the rearward angle at the handgrips). According to the linked specs above, your bars are 750mm with a 15mm rise. Did your other bike you liked better have a bigger rise vs. your saddle height? If that bike is still around, looking at the two side by side will be helpful. If the Powerfly has your body leaning over differently, less rise or more in addition to more length could be helpful (also I've gotten great results from short 45-degree stems that only lift by a centimeter or two. Ritchey made the ones I use).
Go really wide, too. I just looked at JensonUSA and an 820mm bar is available for $69.00. If it turns out 820mm is too wide, handlebars have hashmarks on them so you can cut them shorter. The one I am looking at is marked to go all the way down to 720mm. The point being its a whole lot easier to cut excess material off than it is to add it on.
But before you spend Dime One on replacement parts, dig into your suspension specs and make sure its tuned for your body weight. Check the manual for your rear shock and make sure the sag etc. is set right. Then experiment with damping settings to see if that makes any difference. Fiddle with the air and damping settings on the front. I'm skeptical that 'wobbliness' can be caused by suspension as for my bikes at least suspension tuning is about perfecting the up/down and to me wobbly is a side to side affair. BUT multiple things together can all contribute, so throw all the spaghetti at the wall.