Constraint on the maximum mass of neutron stars using GW170817 event