Here are two reasons for an accent mark: when the spoken emphasis is not in the "regular" place; and for a word that has a different meaning with the mark than without it
Example: "¿Dónde está el baño?" - Question words such as Dónde need the accent mark; Donde without an accent mark is used declaratively, as in your glasses are where you left them". Dónde and Donde are pronounced the same, because the emphasis is already in the "regular" place. - Without an accent mark, está (from the verb estar "to be) would be esta (pronounced ESta, the feminine form of "this"). Without an accent mark, here are 2 general guidelines for the "regular" place for the spoken emphasis: (1) if the word ends with a vowel or with the letters or the letter n, emphasize the penultimate (next to last) syllable; (2) otherwise, emphasize the last syllable.