I already had a glimpse of the story thanks to a chance reading of the etymology of the French "marmelade", but I enjoyed reading the whole story.
https://www.littre.org/definition/marmelade (~1875) / https://www.cnrtl.fr/etymologie/marmelade (~1980)
Funny thing is it's not sweet at all, more like a very bitter apple.
Jam is generally eaten with something else, compote can be eaten on its own or be a "base" e.g. you'd spread jam on bread but you'd eat compote with a spoon. Compotes are jams but in effect closer to mashes.
doce (sweet) is a sugar syrup with fruits normally mashed, this is not preserve this is made to be served. compota (jam) is mashed whole fruits with sugar (pure de frutos). geleia (jelly) is fruit juice jellied or thicken. conserva (preserve/compote) is whole fruits preserved in a sugary syrup. marmelada/goiabada is the same as a compota whit a mashed whole fruits with sugar, but since these 2 fruits create a thick jellied paste, we give it a proper name.
sot he is talking about is a conserva/preserve/compote is all the same thing, its a whole fruits you cant spread that, its for eating or making other things like cakes and such and Portugal has plenty of those as well hehehe :D
https://www.thekitchn.com/whats-the-difference-between-jam-j...
Also, the husks and pits (what remains) of the quince are used to make a quince jelly, that we call "geleia de marmelo" (a liquid jelly):
https://translate.google.com/translate?sl=pt&tl=en&u=http%3A...
In English you have jam and jelly; in Portuguese we have compota which is jam made from fruit pulp, geleia which is liquid jelly with a consistency of jam usually made with the rest of the fruit like husks and/or pits (though the name is also used for other products like bee's royal jelly), and gelatina which is the solidified jelly.