Two melodies for one chord progression

So I’m working on a song and seem to have developed an ok understanding on how to link one melody to a chord progressions. But when I have two overlapping melodies played by different instruments that both match the chord progressions on their own, they sometimes don’t sound that great together. They are in the same key and both match the chords. So my question is our there any guidelines for writing two melodies that overlap during on chord progression? What to avoid? What is the impact of different rhythms on harmony?

Check out counter-point. :smile: https://en.wikipedia.org/wiki/Counterpoint

It could also be a mixing problem you have to solve in your DAW.