How do I finger a chord such as G (GBD) when the melody also requires playing one of these notes, such as B or D? Do I do an inversion to avoid the conflict? I'm brand new at this and using EZ Play books. Thank you.
Well, naturally it depends on the instrument in question (hint hint). But usually one would not jump to out-of-line inversions but rather play the melody note at melody strength and timing and let it serve the chord role as a side job. When the chord note and melody note don't share the exact same timing, one might slightly interrupt the resulting double note enough to give it a separate attack and/or release for its "other" role.
This happens all the time, because the melody notes are often chord tones.
On piano, if you are playing the melody (no singer, for example), we often want to play the chords underneath the melody. That helps us hear the melody, because it's the highest part.
This is where inversions come in. If the melody has a B, then we want to choose a voicing of G which has B as the top note. Beginning students often just play chords in their root position, which resulted in a disjointed sound. If you choose your inversions to fit the melody, you'll get a much smoother sound.
If you're not playing the melody (because someone else is), you have a little more flexibility. In fact, you may want to avoid the melody notes, so that you don't make the sound too muddy. With experience, you'll figure out the appropriate style of accompaniment for each song you play.
So, for now, try and choose an inversion where the melody note is the top note of the chord. As you get more experience, branch out experiment.