From what I could grasp from your question, you are unable to understand how to find maximum frequency in the data and especially the line "the highest frequency in the spectral analysis is 1 cycle/2 months".
I believe breaking down what is happening in the documentation could help.
The first plot shows the number of accidental deaths per month over 6 years. There are clear oscialltions, which suggests a strong periodic/seasonal pattern.
The documentation then decides to calculate Frequency spectrum to find out which frequencies contribute significantly to the variability in the data. They decide to sample the data monthly so sampling rate is 12 samples / year and as per the concept of Nyquist Frequency the highest frequency than can be detected without alisaing is 1/2 the sampling rate which is 6 cycle / year or 1 cycle / 2 months. The overall length of data is 72 samples (6*12). So they created frequency bin from 0 to 0.5 at intervals of 1/72 to plot frequency spectrum accurately.
Here is the documentation of 'fft' for your reference
I hope this helps!