Perception of taste is controlled in large part by a complex combination of chemical reactions happening on your tongue.
There are several dozen different genes that encode taste receptors which fall broadly into two families (bitter and sweet). Thousands of years ago, bitter taste receptors were essential to prevent us from eating poisonous things - but today, humans are much more tolerant to variation in this genes. Even if you have lost some ability to taste poisonous foods, chances are low that you will die from this! Over the past decade, scientists have used genome-sequencing to study taste preferences and identify the genes contributing to these preferences.
Does coriander taste like soap?
A research paper published in 2012 explained it well:
"The leaves of the Coriandrum sativum plant, known as cilantro or coriander, are widely used in many cuisines around the world. However, far from being a benign culinary herb, cilantro can be polarizing—many people love it while others claim that it tastes or smells foul, often like soap or dirt. This soapy or pungent aroma is largely attributed to several aldehydes present in cilantro. Cilantro preference is suspected to have a genetic component, yet to date nothing is known about specific mechanisms."
These researchers identified a specific genetic variant (a single letter difference in ~3 billion) that contributed to this phenomenon.
This genetic variant is described by a specific identifier.
Salty or Sweet Snacks?
The genetic testing company 23andMe asked users a simple survey question to try to understand why some people reach for a salty snack and others have more of a sweet tooth:
"When you’re in the mood for a snack, what kind of snack do you usually reach for?" The options were: (A) Sweet (B) Salty (C) Both (D) Neither
Participants were split about 50/50 between preference for salty and sweet. The researchers indentified several genes with a strong association to snack preference. One of those sites, called rs838133, is near a gene called "FGF21" which encodes a hormone that regulates blood sugar levels.
Most genetic variation has a very small effect!
Most changes to your DNA have very small, or no effect at all. With the two examples above, even though there is a significant effect of genetic variation on coriander soapiness or sweet/salty preference, these genes only account for 10-20% of the variation. Many complex traits (taste, behavior, etc) have dozens or hundreds of different genetic variants that contribute in small, but meaningful ways.