Do they both mean "to add", or is there some other context that I don't understand?
Thank you in advance!
You drive to a gas station to "加油". We don't say "添油".
If you add some firewood to a campfire, we usually say "添柴". If you say "加柴", if still makes good sense, but does not sound as natural as "添柴".
Otherwise, the character "添" is usually used with other characters, like "增添".
Although ""增添" and "增加" have the same meaning, they're not fully interchangeable.
Just as in English, there are situation where the same meaning is present with different words. For example:
1 + 1 = 2
We said 1 plus 1 equals to 2, or we can say, while not as common, 1 add 1 equals to 2.
Now take another example:
Add more oil to the pan
using plus on above sentence will be arguable.
Now a third example:
"Our family have a new member!" (a new born)
Now, in a sense, a new family member is 'add' to the family, however either 'add' or 'plus' will fit into the sentense.
Now back to your question, both 加 and 添 means "to add". There are times where they are interchangeable - Mangoyogurt's answer actually provides some sort of negative example - "加油" and "添油" are both valid where 添油 is more commonly used in ancient times.
For the first example: 1 + 1
, we will say "1 加 1" but never "1 添 1".
For our last example (new family member as a new born), we will say 添丁.
A good example for these 2 words: the word "Additive" in Chinese is 添加劑
I hope that gives you a sense on these 2 words' usage and their meaning.