Many elevators have placebo ones. It might behoove you to test it out sometime - is the button actually working immediately or is it taking time after pressing (or multipressing) the button? Many elevators ignore the button and close when they want but people still think/feel like they were the cause.
As I understand, basically no elevators have placebo close door buttons, but some have ones that only function when the elevator has been placed in manual operation mode, which requires a special key and is usually only done for service, emergency operations, and other special circumstances, and in which mode doors do not close automatically.
You can find photos of elevator control panels where the "close door" button is falling off, and is revealed to be just glued on with no electronics behind it. So commonly the button has a special-operating-mode purpose, but not always.
It's like the 'close door' button on an elevator. Some people just want to feel like they are doing something.