It depends where you catch the train. The cheapest way is to cross the border by bus/minivan from Lublin or Chelm to Kowel. (It can be very hard to find this information online.) Then book the train from Kowel to Kiev in Ukraine. If you go by train from Lublin the price is quite high, (you are paying two railroads for the tickets and reservations) and you also must buy the ticket and reservation before the train leaves from Warsaw. However, taking the train across the border is more convenient, especially in bad weather in the winter.
I've read online the sleeper train costs approx £7-£12 but someone else says £50 each way.