This is a postmortem artefact known as "Swiss cheese brain" in which the postmortem growth of gas forming bacteria such as Clostridium perfringens create the holes.