Have Jeep Questions? Ask a Jeep Repair Expert for Answers
Sounds like the hood latch is bad. It was probably not all the way latched and that is why the alarm starting going off, then once you opened it and closed it now it is stuck closed.
If my answer has helped you, please help me by rating or accepting my answer. This does not cost you any more, it just allows me to be credited for my work. You can always ask follow up questions after rating or accepting. Thank you