This page describes how you would modify Nagios configuration files, so whilst this works with both Nagios Core and Nagios XI it really only applies to the Core edition, with XI you would be using the wizards.
It is recommended that your config files go in your own directory rather than the standard directories or editing the standard files. The first step to doing this is to add your config directory to the main nagios configuration file:
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
/etc/rc.d/init.d/nagios reload