I remarked that some words can be modified by adding a 성 ending. For example, 필요 which means 'need' can be modified to 퍌요성, which stands for 'necessity'. Also, we have 가능 'possible' and 가능성 'possibility'. It should be noted that these two examples indicate the status of something.
Is there a grammar rule that explains the change of a name N into this N성? And if so, what changes in meaning does it convey?