How to Load Node, File, Taxonomy Entities by ID in Drupal 8+
To load node details using its id in Drupal 8+ uses the following syntax:
$node_details = Node::load($nid);
$node_details->field_FIELD_NAME->value;
We can load multiple nodes in Drupal 8+ using load multiple() function. Note that the parameter should be an array of ids.