Slovenia's government has refused to allow entry to a train carrying more than 1,800 refugees from neighbouring Croatia.