If you are speaking of a non-biological construct, such as an AI or a philosophy, one can grudgingly accept the “metaphor” excuse, as it is patently obvious that such things do not have possess Deoxyribonucleic acid.
When referring to biological constructs, it automatically implies actual genetic coding. The nature (immutable) over the nurture (learned from interaction with the world and society).
We have fear instincts. What we fear is taught – how early we learn it varies. Fear also ≠ hatred. That we should actively hate someone or something is taught, not ingrained.
There is no hate gene.