Try this one -
DECLARE @XML XML
SELECT @XML = '
10
20
0
15
20
5
'
SELECT
value = SUM(t.value)
, t.id
FROM (
SELECT
value = p.value('.', 'INT')
, id = p.value('./../@ID', 'VARCHAR(50)')
FROM @XML.nodes('/Parent/Child') t(p)
) t
--WHERE t.id = 'p'
GROUP BY t.id