There are several words that have the same spelling.
In c'est de l'eau, de l' is a partitive article (article partitif). It is the singular, contracted form of the partitive article; other forms are de la bière (singular feminine), du vin (singular masculine), des oranges pressées (plural). Many uses of the partitive article can be expressed in English with the word some (even if it would be more idiomatic to omit some here): “the jug contains (some) water”.
In une carafe d'eau, d' is a preposition (the contracted form of de). This is one of the few cases in French where a common noun is not preceded by an article. Roughly speaking, de followed by a noun with no article indicates the origin of a process, the whole from which a part is made, or the purpose of an object (for more details: TLF de¹ I.B). Une carafe d'eau = a jug of (= containing) water.¹ Une carafe de verre (en verre would be more idiomatic here) = a jug (made) of glass. Un cœur de pierre = a heart (made) of stone. Une rangée de chaises = a row of chairs.
There are other cases where that same preposition de is followed by the definite article le/la/l'/les; it is then contracted to du / de la / de l' / des. This is the case when de indicates possession: la maison du boulanger = the baker's house. This is also the case when de indicates an attribute of an object: le bord de l'eau = (lit.) the edge of the water. This is also the case in most cases when de introduces a complement of a verb: sortir de l'eau = to get out of the water.
A jug designed to hold water would be une carafe à eau.