In order to create a new product attribute in Magento 2 please go to Admin Panel  >  Stores  >  Attributes  >  Product.

Magento 2 Product Attribute

Once you've got there press the Add New Attribute button.

Mageneto 2 Product Attribute, Add New Attribute

Attribute Properties

1. Enter a Default Label of an attribute. It will be displayed on the admin panel.

2. Choose a type of an attribute in the Catalog Input Type for Store Owner field. There are such available values here as: Text Field, Text Area, Date, Yes/No, Mutliple Select, Dropdown, Price, Media Image, Fixed Product Tax, Visual Swatch,Text Swatch.

3. Select yes in Values Required field in order to make the attribute required for products. In this case, you won't be able to save the product with this attribute if you don't set its value.

Magento 2 Product Attribute, Attribute Properties

Advanced Attribute Properties

1. Set the Attribute Code. If you leave this field empty, the attribute code will automatically be generated from the default label.

2. In Scope you choose a level the attribute will be edited on. As far as Magento 2 is a multilingual and multi-website platform it is better if it is the text field attribute to leave it on a Store view level. In case attribute value doesn't depend on site or language it will be wiser to choose Global.

3. Set a Default Value of an attribute. We pay your attention to the fact default value won't be automatically set all existing products. It will be added only after the resaving of product.

4. In the Unique Value field set Yes, if you don't want the same attribute value to be applied to different products, e.g. SKU attribute should be unique.

Mageneto 2 Product Attribute, Advanced Attribute Properties

5. In Input Validation for Store Owner set filter that will be used before saving a product to validate an attribute value.

6. filter Yes in the Add to Column Options field in order to add the attribute to the list of column options in the product grid.

7. If you want this attribute to be used while filtering of products choose Yes in Use in Filter Options field.

Magento 2 Product Attribute, Advanced Attribute Properties

Manage Labels

Set a Default Store View which will be displayed of the Storefront. In case you have a multilingual site, you can set a label for each language.

Magento 2 Product Attribute, Manage Labels

Storefront Properties

1. If you want the attribute to be used while search, choose Yes in the Use in Search field.

2. In the Comparable on Storefront field you can select whether this attribute will be used on compare product page.

3. In Used in Layered Navigation you choose the attribute to be used in layered navigation.

4. You choose whether the attribute will be used in layered navigation search in the Use in Search Results  Layered Navigation.

5. In Position field, you set the position of the attribute in the layered navigation.

Magento 2 Product Attribute, Storefront Properties

6. Choose Yes in the Use for Promo Rule Conditions field if you want this attribute to be used in rule conditions for cart price rules and catalog price rule as well.

7.  In order to make the attribute displayed on a product page in additional options, choose Yes in the Visible on Catalog Pages on Storefront field.

8. Choose Yes in Use in Product Listing to add this attribute value to the PHP product object in a product list (product collection).

9. If you want the attribute to be used for the sorting process choose Yes in the Used for Sorting in Product Listing field.

Magento 2 Product Attribute, Storefront Properties

Once you have finished don't forget to press the Save Attribute button.

Magento 2 Product Attribute, Save Attribute

Assign to Attribute Set

Afterwards, go to Admin Panel  >  Stores  >  Attributes  >  Attribute Set, choose the attribute you need, drag and drop it from the Unassigned Attributes to Groups.

Magento 2 Product Attribute, Attribute Set Name

Once you have finished don't forget to save the attribute set.