XMPP clients will prefer to use encryption, if available. This hampers packet inspection (for all the good reasons). To be able to inspect XMPP traffic, you'll have to disable client connection encryption server-sided. This will prevent clients from using encrypted connections when communicating with the server. Note that clients can still choose to encrypt the content of their communications, through the use of OMEMO or OTR-like end-to-end encryption strategies.
To disable client connection encryption in Openfire, open the admin console, and navigate to Server > Server Settings > Client Connections.
There, open the 'advanced settings' option of the first block, and select 'disabled' for the "STARTTLS policy" option.
If your goal is to learn about XMPP, there are alternative, and potentially easier ways. XMPP is an open standard and is well documented. A very good way to learn about XMPP is to read it's specification at https://xmpp.org/extensions/ (Start with RFC6120 and RFC6121).