Gear is not changing when car accelerate. RPM is going up.
Year, make and model would be helpful. If your car has a transmission dipstick, follow the procedure in your owners manual for checking the fluid.
If it is low, use ONLY the proper fluid for your car.
Is there a warning/information light or message being displayed? Assuming this is an automatic transmission then a design feature will cause certain problems with the transmission/engine to keep the car from up-shifting, known as “limp” mode.
Your problem could be fairly minor or major. Certainly more information from you to us is required to receive any valuable suggestions other than wild guesses.
Check your transmission fluid dipstick most that’s where most problems lie in.