How to get the newly created node ID in drupal module 8?

I have a content type form that is displayed in a popup window. Once the user completes the form and clicks submit, I have to obtain the node ID and update it in the user table.

How to get the last node identification created using the module?