Garage door opener will not close unless the wall button is held
99% of the time, the issue is the door sensor. Usually an infrared beam, it runs across the bottom of the doorway to reverse the door if anything blocks it. You'll need to check them. There's typically a green light unit (transmitter) and a red light unit (receiver). The red light will flash if there's no beam from the transmitter.


Make sure they are aligned properly. If someone bumped it, it can fail easily
Make sure the sun is not hitting the transmitter or receiver. In the spring and fall, it sometimes hits mine and causes issues at certain times of the day.
Make sure nothing is covering any holes. My newer Genie unit has transmitters that have a nice hole for spiders to build a nest in. A can of compressed air can help with that