Secrets are all over Doom: Eternal, and there is a handful found in the Fortress of Doom, the hub area you frequently visit in-between missions. Unfortunately, you have to wait for a certain point in the game to gain access to one of them, and the other is hidden behind a specific unlockable armor.
The easiest one to access is the one found on the right side of the ship. It’s hidden behind the Preator unlockable armor set, which you can have your Doom guy wear during the campaign for two sentinel batteries. After you give the batteries, proceed to the back of the room and go to the left. There’s an opening you can drop from, and mid-fall you want to turn around to dash into a small opening at the bottom, and it’s a cheat code.
The other secret is at the center of the ship. However, you won’t be able to access it until you hook up the Demon Crucible to power the Fortress of Doom. After this, you can go after it. You need to go where the Demon Crucible is floating, and then look to your right at the upper section. The middle window should have a small, red dot you can shoot, and behind you a vent opens up you can use to do a jump boost. It takes you to the location you need to be, and you will be standing right in front of the secret, which is a cheat code.
There are other collectibles throughout the ship and many of them require at least two sentinel batteries for you to access. You need to obtain them by going through the missions in the game, which you can freely access by going to the mission select at the front of the Fortress of Doom.