I'm going to assume you have been riding a 16" or 20" folding bike that looks like this Dahon:
and that you're trying either a hybrid-commuter style like this rapide
or a suspension MTB something like this KTM
Generally the differences are that folders are very "responsive" in their steering. You turn the bars and the front wheel turns very quickly.
By comparison, a MTB has much larger wheels, being 26" to 29" plus they often have larger tyres, also adding weight at the rim. The upshot of this is that it takes more effort to turn the bars on a MTB. This is slightly offset by having longer bars - some are as much as 500mm wide but this means more movement of the hands is required for the same steering change.
In a folder its a relatively upright position. They tend to not ride hands-free very well so you need a hand on the bars at all time. But your back can be upright.
A MTB position is more leaning-forward too, although not as much as a drop-bar. So you have a little more weight on your hands than on a folder. This may create steering inputs until you learn to put more weight on your feet.
Wheelbase the distance between front and rear wheel contact points.
A 20" folder has a wheelbase of about 102 cm, and a 16" is about 97 cm. Compared to a MTB at 110 cm to 120 cm. Short wheelbases are inherently twitchier, and long wheelbases are more stable at speed while cutting a longer curve.
16" vs 20" wheelbase
Your folder will have no or almost no suspension. So its firmly in contact with the road. A MTB with front suspension will feel strange if you're used to braking and turning, and in extreme cases can throw you off the bike when the suspension loads up and then releases. If you buy a bike with suspension, look for a lockout for road usage. Makes the ride less "wallowy"
Rear suspension also sucks your power. If you're average weight the bike will probably be about right for setup, but light and heavy people need the rebound and sag set properly. Many rear suspensions suck your power while pedalling too - so rear suspension lockout is handy on the road. Or don't get suspension at all.
Note this won't apply to the rigid commuter frame.
Not mentioned in your question but added for completeness, pedal assist is frightening if you've never used it before. This is when a bike has a motor that "multiplies" your pedal input using electric power. So when you push the pedals to take off, Pedal Assist kicks in and gives you your own personal tailwind. This can be highly disconcerting.
The only fix is to lower the pedal assist input to zero or to its lowest assist value while testing a bike. Only increase PA percentage as you become used to the bike and the motor's functions.
Here's the big one....
You spend under a minute riding this MTB. It could take anything up to 30 minutes to get "dialed in" to the various inputs required.
Changing between significantly different bikes can be hard
I tried a SWB recumbent recently, and it felt like being a noobie all over again. Took a good 30 minutes to get up to speed and I could feel myself going through the plateaus of "this is horrible" then "its not so bad" backwards through "ouch ouch ouch" then over the ridge of "Yay I got it!" only to drop down the other side of "No I don't got it?!" After 15 minutes I was good for a ride around the block, but in no way was I ready for a century, and I probably would not react correctly in a crisis or accident. That comes with many hours on that bike (or a lot of innate talent)
The odd thing is folders are considered hard to ride and the fact you're comfortable on one shows that you possibly need to "unlearn" some riding behaviours. See What makes a folding bicycle so difficult to ride? for info on folders.
Things for you to try
- Spend 30 minutes practising in a safe space with no cars and minimal obstacles. Take your time.
- Press harder on the pedals to take weight off your other contact points
- Commit to turns - don't vacillate. Know how much lean is required for a specific angle of turn at different speeds.
- Start by scootering around, and get used to the turning before you start worrying about pedalling. A small slope can be helpful. If this sounds like "how to get a kid riding a 2 wheeler" its pretty much identical.