Manual:$wgExtraNamespaces

Details
$wgExtraNamespaces is used to configure additional, custom namespaces for a wiki. It can also be used to rename the default namespaces.

This is covered in detail on Manual:Using custom namespaces. Note that the first custom namespace should use the ID, as IDs from   to   are reserved (and negative IDs have a special meaning). The maximum namespace ID was  on some older (< MW 1.5) MediaWiki versions, but 16-bit namespace numbers (through to  ) are supported in all current releases.

Example
To add a namespace with the name "Foo" to your wiki you need to create two new namespaces: an even number for Foo: pages and odd number for their associated Foo_talk: pages.

You must choose numbers that don't conflict with other namespace numbers on your wiki. As a convention, the namespaces numbered 100-199 are reserved for site-specific namespaces, although there are some extensions that don't follow this convention.