Prophet Adam (PBUH) had a number of children. His first two were called Qabeel (Cain) and his twin sister Eklema. His second two were called Habeel (Abel) and his twin sister Labuda. The boys grew up and both had jobs - Habeel was a shephard and looked after the animals while Qabeel looked after the orchard and grew fruit trees and vegetables.
It was customary in those days, as a sign of appreciation for the bounties of Allah, that people made material offerings to God in the form of burnings or slaughtering of livestock (of which they ate some parts so that it would not be a waste).
Cain [Qabeel] brought some fruits of the soil as an offering to the Lord.