In Hinduism Agni is god of fire. Rather he is fire. He brings prayers to the gods. Btw, the name Agni is cognate with the root for 'ignite'. Fire also dispels darkness and destroys ignorance.
All Hindu rituals use fire in some way, usually an oil or ghee lamp. It's offered to the gods then to the devotees. That's why you see Hindus cupping their hands over the flame then bringing their hands to their eyes.
One poem from rig Veda to Agni (God of fire) (Mandala 2)
1. With sacrifice increase Jātavedas(flames) ; sacrifice to Agni with oblation, with song at length
when he is kindled—(Agni) receiving pleasurable offerings, possessing
solar glory, the heaven-ruling Hotar, sitting at the chariot-pole in the
(ritual) enclosures.
2. Toward you have the nights and the dawns bellowed, o Agni, like
milk-cows in good pastures to their calf.
As the spoked wheel of heaven [=sun] (does) through the human (life-)
spans, through the successive nights you shine, o you of many favors.
3. Him of wondrous power have the gods fitted down at the base of the airy realm [=on earth],
as their spoked wheel of heaven and earth—Agni with his flaming flame—like a chariot worthy to be acquired,
to be proclaimed like an envoy (installed) among the settled peoples.
4. Him, growing in the airy realm (as) in his own house, very bright like
gold, they have set on a meandering (course),
appearing (like) the flying (udder) of Prsni [=cloud], observing with his
eyes along (the whole length of) both races [=gods and men], like the
protector of a path [?] .
5. As Hotar (chief priest) let him encompass the whole ceremony. Toward him do the sons of Manu (humans) stretch out, with oblations and with song.
Golden-lipped, growing on these (hearths), quivering, appearing like
heaven with its stars, he perceives along (the whole length of) the two
world-halves.
6. When you have been kindled, (shine) richly for our well-being; even
after you are entirely extinguished, shine wealth upon us.
Turn the two world-halves toward here, for our easy progress, o god
Agni, (for them) to seek out the oblations of Manu.
7. Give us, Agni, lofty (prizes), give (prizes) in thousands. Open up the
prize like a door, for (it) to be famed.
Turn heaven and earth eastward with a sacred formulation. Like the
blazing sun, you have made the dawns flash forth.
8. On being kindled through (all) the dawns and the nights, like the sun he has shone with red radiance.
With the libations of Manu he conducts good ceremonies—the king of
the clans, the guest dear to Āyu.
9. In this way, o foremost Agni, (hymnic) vision swells for us among the immortals dwelling in lofty heaven through the human (lifespans)—(a vision like) a cow giving milk to the bard in the (ritual) enclosures,
(bringing) by herself multiform (prizes) in hundreds at her
impulsion.
10. May we, o Agni, by our steed get in sight of (wealth) in good heroes, or by our sacred formulation distinguish ourselves beyond (other) men.
Let our brilliance blaze upward among the fi ve peoples like the sun,
diff i cult to surpass.
11. O mighty one, become the one for us to proclaim—(as him) in whom the well-born patrons find nourishment,
whom the prize-winners approach to sacrifice, o Agni, as you shine
amid (our) own offspring in (your) own house.
12. May we both, the praisers and the patrons, be in your protection, o
Agni Jātavedas.
Over goods and wealth—much glittering, very abundant, consisting of
offspring and good descendants—exert your control for us.
13. The patrons—those who dispatch to the praisers a gift tipped with cows and ornamented with horses, o Agni—
lead both us and them forth to a better state. – May we speak loftily at
the ritual distribution, in possession of good heroes.