Weight lifting can be very beneficial to cycling.
From your comments, I think you are asking basically as a roadie.
There are many body weight exercises that you should already be doing.
These include lower body exercises such as properly performed squats and forward and rearward lunges. Sets of 20-50 reps. These will improve your lower body strength.
I know you already stated that your lower body was strong but most road riders tend to be locked into the same position. Performing lower body exercises out of the riding position will increase strength and power while reducing the risk of an over use injury.
Most cyclist need to use the “other side” of their legs too.
This usually means running, jogging or hiking.
You should also look at “six stretches every cyclist should do”.
If you mountain bike, then upper body is even more important.
Push ups and bent rows are a must.
Pull up and Lat pull downs are very good but there is no need to go behind the neck.
Oppose pullups and lats with dips, not military presses.
I generally advise people over 30 years to avoid military presses or any exercise that has you pushing the weight over head and do not do exercises that place the weight or the bar behind your neck.
This is because the risk of rotator cuff injury.
Generally “again over 30”, dumbbells are preferable to barbells because it allows you to have more freedom in range of motion - again, this decreases the risk of injury. They also encourage the use of all the supporting muscles.
That is also the argument against most of the weight machines in the gym - they lock you into the same repetitive range of motion and do not require development of supporting muscles.
The biggest risk to a male entering a public gym is the tendency to feel the need to lift bigger wts.
This can quickly lead to an injury.
Are you competitive? How many times on Zwift do you speed up to prevent someone from passing?
Moving to heavier wts seldom improves endurance performance but proper weight lifting will.
The desire for heavier wts draws people away from the dumbbells and to the barbell and to the machines because without having to develop the supporting muscles, you can lift bigger wts.
There a good video on You tube that’ titled “The 7 worst weight lifting machines or exercises in the gym”. Something similar. There are actually several similar videos.
A lot of folks in the gym do exercises wrong, perform exercises that really will have no benefit and are using weights or performing exercises for show.
The gym will have some speciallty equipment that is very useful.
bench press and inclined bench presses. Using the lat pull down is a great way to build up to do pull ups though, I have seen people incorporate an elastic band to assist doing pull ups.
And, a knowledgeable trainer “may be” at the gym.
I’m sorry for the long post but I just feel most people might be better served installing a pull up bar at home and getting 10-15-20 - 25 lb dumbbells and performing body weight exercises.
OK, that said, you asked for advice not an opinion.
Perform body wt push ups, pull ups, dips, squats, forward and rearward lunges.
Use dumbells for bicep curls, triceps curls,bench press and inclined bench and bent rows.
Perform sets of ab crunches and planks.
Then do the stretches.