In case you are unable to somehow enable the feature you are looking for inside OpenOffice, you can use macOS's Character Viewer or the combining characters (diacritical marks), which you can get with dead keys, to get accented characters. A regular (keyboard) key that gives a combining character when pressed along with a modifier key such as the Alt ⌥ or Shift ⇧ key is called a dead key.
The keyboard shortcut for the Character Viewer (Kntrl ⌃+Command ⌘+Space ␣) does not seem to work inside OpenOffice's macOS version but, when enabled, you can access it by clicking on the Input menu to the right of the menu bar at the top of your screen. You can enable the viewer via System Preferences -> Keyboard -> Show Keyboard & Emoji Viewers.
To get an accented character using a combining character instead, first put down a combining character such as ` ' " ~ ^ and, quickly after that, the letter to be modified. For example, putting down the combining character ~ and the character a right after that would give you ã. You may have to press the Alt ⌥ or Shift ⇧ key along with one of the regular keys on your keyboard designated as a dead key to get a certain combining character depending on how your keyboard is configured.
The dead key yielding a certain combining character may be different than the key or key combination you press for a similar-looking punctuation mark. Because dead keys differ among different keyboard configurations (US and non-US QWERTY), you might either use the Keyboard Viewer or do some trial and error, i.e. press the Alt ⌥ or Shift ⇧ key and each one of the regular keys on your keyboard at the same time, to discover all the key combinations with the dead keys on your keyboard.
To find the key combinations through the Keyboard Viewer rather than trial&error, you should first enable the Keyboard Viewer via System Preferences -> Keyboard -> Show Keyboard & Emoji Viewers (same sequence as the Character Viewer). Then open the Keyboard Viewer from the Input menu to the right of the menu bar at the top of your screen (similar to the Character Viewer again). Once the Keyboard Viewer is opened, press and hold the Alt ⌥ or Shift ⇧ key and the dead keys are keys highlighted in orange. To utilize a designated key as a dead key in OpenOffice and elsewhere, you need to press the dead key along with whichever key (Alt ⌥ or Shift ⇧) you used to expose it in the Keyboard Viewer.