Can two nuclei with the same number of protons and neutrons be different?
I think that what you are asking about is related to the idea that there are energy levels in the nucleus akin to the energy levels for electrons around the nucleus.
This is called the shell model of the nucleus.
In this model there are energy levels for the nucleons which are slightly different for the protons and for the neutrons.
Each energy level can be occupied by two particles of the same type and so when the bottom energy level (shell) is filled with 2 neutrons and 2 protons a very stable nucleus is formed $(^4_2 \rm He)$. When other shells are filled the nucleus tends to be very stable as per the filling of electron shells with the result of the very stable (chemically almost inert) noble gases.
If nucleons are above the ground state (an excited nucleus) they can jump down to a lower energy levels with the emission of a gamma ray photon. The gamma ray photon has much more energy than the energies associated with electrons jumping down energy levels because the spacing of the energy levels in a nucleus is much greater than the spacing between electron energy levels.
The nucleus can be in an excited state, exactly in the same way as an atom can (where the electron jumps up to a higher energy state). See e.g. Nuclear Isomer.