Building off of this question: Why does freshly cut grass smell like a watermelon?, is it usually the case that things that we perceive as having similar smells are, in fact, the same or a similar chemical hitting our noses (as in the case of cis-3-hexanal in watermelon/cut grass), or is it often a cognitive thing (we're bad at parsing smells, so when confronted with a new smell, we fish around in our experience to find something that seems familiar, even if there's not much chemical similarity)?
With regards to the similar chemicals having similar smells, it does seem that there are trends with smell association and functional group. This wiki article has a good list of compounds and their smells, and some classes definitely give similar types of smells, amines are rotting/fecal smells (hence the names putrescine and cadaverine), while esters are often fruity. As you can see its not perfect, but there are definitely patterns.
There are some weird dose-dependent effects like in the case of indole which is labeled as flowery/fecal, which are two pretty distinct smells. Apparently its fecal at high doses, and smells like jasmine at low doses. My guess is that this has to do with different binding affinities of the different olfactory receptors (ORs) that are expressed in the olfactory receptor neurons (ORNs). Many odorants will bind to multiple ORs, which means they will stimulate a characteristic sub-population of ORNs. The binding to the different ORs will of course have different affinities. This probably means that at low concentrations of indoles, you stimulate a certain population of ORNs that your brain recognizes as nice flowers, but as you increase the concentration you get the activation of ORNs with ORs that have a weaker binding to indole, changing the population of activated ORNs to one that your brain recognizes as feces. Its definitely a strange pairing though..
I'm not familiar enough with the literature to know if the similar smelling things have similar ORN activation patterns, but my guess would be that they do. If you have a population of different ORs that your odorant is binding to, a slightly different odorant will probably bind to a similar subset of ORs, just off by a few if its missing or has gained a functional group that is in the binding pocket of some of the ORs. This probably means that if you are presented with a chemical that you have never smelled before, it will probably activate a similar ORN population as other similar chemicals, and your brain will probably say it smells like one of those similar chemicals.