Node access control based on users at the node edit page I want to ask is it possible to assign customized roles to particular users at the node edit page? For example, the node author/admin can assign "editor" role to user A &amp; user B and assign "admin" role to user C at the node edit page. The node access control is different among different nodes and different users. 

I found some related modules such as Permissions by Term and Permission by field but none of these can perfectly fulfill my requirements. I am using Drupal 8 so some modules may not suitable for me.

Is there any solution for that?
You could use the Group module for this. This module allows any node to be "assigned" to some group. And then it depends how you configure the group roles (which are NOT the standard Drupal roles) about who has what kind of permissions.

For your case, create a group type named something like "Node Authors", and then create a "Group" for each user (using something containing the user's name as its label). And tune the permissions which come with the Group module (which are different from standard Drupal permissions!) to fit your needs.

After you enable gnode, a submodule of the Group module, you can assign any node to a group. In D7, you could simply do so at the node edit page: there is an extra form field on the node edit form which can be used to select the group that you want the node to be assigned to. However, in D8 this is no longer possible, for reasons explained in this comment, and which states:


  ... all content-to-group relationships are now fieldable and we therefore need to ensure the user is presented with the fields that were configured on said relationship. A simple auto-complete to select a group would therefore not work.


Therefor, in D8, this is what you have to do instead, as described also in the feature request "UI: more easily select group for a node":


Open the Groups list and click through it.
Select the appropriate Group.
Go to Group content.
Select "add group content".
Select which group content.


More info:


Refer to "What are the various roles supported by the Group module?" for more details about the supported roles.
Refer to my answer to "How to configure access to courses for teachers and students?" for a sample configuration.