BUG: frequencies.get_freq_code raises an error against offset with n != 1
Fixed a `frequencies.get_freq_code` raises `ValueError` against offset instance with n!=1. This is needed for #7832.

```
# OK
>>> import pandas.tseries.frequencies as f
>>> f.get_freq_code(('D', 3))
(6000, 3)
>>> import pandas.tseries.offsets as offsets
>>> f.get_freq_code(offsets.Day())
(6000, 1)

# NG!
>>> f.get_freq_code(offsets.Day(3))
ValueError: Unknown freqstr: 3D
```

Also, added docstrings and tests which make frequencies behavior understandable.
