Your question isn't completely clear, but assuming you want to know whether the root element has a <cocktail>
child with value name
, this would work:
bool exists = doc.Root.Elements("cocktail")
.Where(element => element.Value == name)
.Any();