Hi,
You pay National insurance on earnings from employment, whether this is via PAYE operated by your employer or when you are registered as self employed earner.
You can find more information on
National Insurance National Insurance: introduction: Overview
Depending on the class of National Insurance Contributions (NICs) deducted see
National Insurance: introduction: National Insurance classes
They may or may not help towards your state pension entitlement and or when applying for benefits.
If you require a more in-depth personal answer you will need to write into the department for a liability decision.
Thank you.