Homebrewer here as well. There's plenty of chemical compounds that yeast produce that give various notes that kind of resemble something else. For instance aldehydes (notably acetaldehyde) is a yeast byproduct that gives off a "green apple" flavor. Usually in beers this is considered a flaw, but I notice that some wines promote that aspect as positive if it's not overwhelming.
Diacetyl is another one -- this has a "buttery" flavor. This is considered a flaw in some styles, but is naturally present in others (English ales notably often have a little bit of this in it). Some wines are very "buttery", I understand in particular those that use a process called malolactic fermentation (where diacetyl is a byproduct) are prone to it.
From what I can Google you can get chocolate notes in wine either from the tannins in grapes, or the charring process used on barrels. However, I haven't been able to Google specific chemicals. In beer, "chocolate notes" can come from some of the toasted / roasted malts out there (IMHO more on the pale end of the "chocolate malt" spectrum -- darker "chocolate malts" taste more "coffee" like to me).
A fair bit of places offer a "off flavor" kit for beers that allow you to train your tastebuds on at least the common "faults".