Where is knowledge of how the brain works stored? If we are our brains, and our brains know how they work, this means that this information is stored somewhere in the brain, like the inferior temporal cortex is the part of the brain that recognizes numbers. 
Where is knowledge of how the brain works stored?
This type of knowledge is known as "semantic memory"; a type of "declarative memory". We don't yet know where semantic memory is stored in the brain, although there is evidence that hippocampal and/or parahippocampal structures are required to store semantic memory.

The fine details of exactly what a "memory" is in terms of neurobiology, where and how it is stored, and how it is retrieved is an area of neuroscience that is currently under very active research. However, our knowledge is very rudimentary at present.