Congratulations on your decision to learn guitar. It is very versatile instrument and rewarding to play. But as you have probably figured out by now, not the easiest instrument to master. The good news is, it get's easier as you go and you will start to see an upturn in the learning curve as things begin to sink in and gel.
One of the most difficult aspects of playing rhythm guitar for most beginners is well - rhythm. Some never quite get it. But I have found that drummers who learn to play guitar after learning to play drums, seem to have an easier time mastering the rhythm part of guitar playing and often make great guitar players.
Let me mention a few things that I feel are important as it relates to playing rhythm guitar with a drummer (for yourself and any other guitarist who has trouble keeping up with the groove of the drummer).
The first challenge is to be sure your guitar groove and your drummer's groove are compatible with one another (drummer needs to know this too). As you know from learning to play drums, there are many different patterns and beats you can play on drums. You want to learn many patterns because each song has a different groove and the groove established by the drummer needs to match the intended groove of the song itself or things just won't mesh well.
Just as there are different patterns and beats you can play on drums, there are many different strumming patterns that you can play on guitar to establish different grooves. There are probably as many different strumming patterns for guitar as there are beats and patterns for drums. In addition to learning chords and fills and scales (fretting hand technique) you will want to spend time learning different strumming and picking patterns (picking hand technique). In order for your rhythm guitar to mesh well with the drummer, you both need to be playing a pattern that will sync up well with the intended groove of the song and with each other.
Some songs have a signature drum groove or beat that is an integral part of the songs DNA. If you are playing in a band and the drummer knows the groove of a cover song the way the band wants to play it, then you will need to be sure you adapt your strumming pattern with the drum pattern/beat. If the drummer is not familiar with the song (perhaps it's an original vs. a cover) then you as the rhythm guitarist should establish the rhythm and it's up to the drummer to pick a groove that is compatible with the groove you establish on guitar.
When I'm playing solo, I do a more percussive strumming pattern to establish the beat in the absence of a drummer. When playing with a drummer, if we have not rehearsed together, I will start the song with the percussive pattern to allow the drummer to get a feel for the groove I want to establish for the song, and the drummer will choose a beat pattern that matches. Then once the drummer has found the groove I want him to find, I will switch to a less percussive strum and allow the drummer to keep the beat while I emphasize the harmony. But my strumming pattern will be in sync with his drumming pattern.
You would be surprised how much strumming patterns are like drum patterns or beats or grooves or whatever drummers call it. With one strum pattern you may be accenting the 1 beat and 3 beat (in 4/4 time) with a down strum on 1 and 3 and and up strum on 2 and 4. Another pattern could emphasize the 2 and 4 with a more forceful down strum on those beats.
Your question seems to be about keeping the rhythm with a drummer and not singing and playing the guitar at the same time. While it's important to have many different strumming (rhythm) patterns in your vocabulary so you can choose the one most appropriate for each song, you need to be able to sing with the rhythm pattern you are playing on guitar. It's difficult enough to master singing and strumming at the same time. Assuming you can do that and assuming you can learn the appropriate strumming pattern for the song - it is the drummer's responsibility to make the adjustments to get the drum groove in sync with the singer and rhythm guitarist! In a live setting, it's easier for you to sing to the rhythm pattern you are playing on guitar. If the drummer goes in a different direction and you try to follow the drummer, it's going to throw you off every time.
So in addition to learning more strumming patterns, it's just as important for the drummer to follow the rhythm pattern you are comfortable playing on guitar and singing at the same time. As part of a band, the entire band needs to decide what groove they are going for on a particular song and then everyone needs to find a rhythm pattern that works. But if the lead singer can't follow the groove, everything will fall apart.
To help you improve your ability to match your strumming patterns to drum patterns you might try playing to a drum track or even create your own drum tracks for the songs you want to play. Then try different strumming patterns until you find one that matches the beat, and practice practice practice. You will get it.
For more about strumming patterns see this on Stack Exchange https://music.stackexchange.com/a/33731/16897
Here is an excerpt that reinforces and adds to what I stated above:
The strumming pattern you use will have an effect on your ability to maintain an appropriate rhythm for a particular song. On many patterns you may find it helpful to get your wrist moving up and down like a pendulum and keep it going much the same way as if you rest the heel of your hand on a table and tap your fingers to the beat. Depending on the strum pattern you might intentionally miss the strings on every other up-swing or every other down-swing or every third down swing etc. - depending on the strum pattern you want to use.
Good luck and have fun. You will get it!