public class Shop
{
    private static List<Product> products = new List<Product>(){};
}
code is throwing exception:is not abstract and does not override abstract method subList(int,int) in List
public class Shop
{
    private static List<Product> products = new List<Product>(){};
}
code is throwing exception:is not abstract and does not override abstract method subList(int,int) in List
 
    
    You can't instantiate a List, its just an interface. So instantiate an implementation of it e.g. an ArrayList :
public class Shop
{
    private static List<Product> products = new ArrayList<Product>();
}
 
    
    As mentioned in other answers here java.lang.List is an interface. I wish to add just a little more to those. List being an interface  means it defines the necessary contract which must be respected and fulfilled by any class to qualify as a List. Users of such a class can be sure of the contract being followed so without being worried for the internal source code, they can be sure that it follows all the standard predefined rules for being a list.
Interface being just the contract needs to be implemented by some class for realization. An interface itself can not be instantiated, its only the Abstraction you can not have the object of interface without implementing it in a concrete class. 
In java you can either use the keyword implements with a class and then must give implementation for the methods defined by the interface. You can also use annoyonmous class style. But if any class (including such an annoyonmous class also) implementing an interface, you must provide concrete implementation of all the methods defined in the interface. For this you can use 
public interface AnyInterface{
    void anyMethodA(); // methods are public and abstract by default
    void anyMethodB(); // see as the methods just have signature here, no body
}
Now you can use annoyonmous style as below using curly braces.
AnyInterface objectOfAnnoyomousClass = new AnyInterface(){
     public void anyMethodA(){
          // curly braces implies a method body, here you can have the method implemented 
     }
     public void anyMethodB(){
     }
 };
java.util classes have the implemetation of java.util.List such as ArrayList, LinkedList. 
private static List<Product> products = new LinkedList<Product>();
There is plenty of material available for java collections including the very well java docs.
**P.S. static has actually nothing to do with the compile time issue you are having in the code you showed.
 
    
    List is an interface. You can't initialize an instance of an interface. You need to instead initialize a class that implements List like ArrayList. 
private static List<Product> products = new ArrayList<Product>(){};
