Trump said it (full transcript below).
However, he did not make the remarks during the COVID-19 pandemic in 2020 but years earlier during a campaign event in November 2016.
In April 2020, as the death toll in the United States from the COVID-19 coronavirus disease pandemic approached 18,000, a video supposedly showing U.S. President Donald Trump encouraging people to vote even if they were gravely ill started to circulate on social media:
This is a genuine video of Trump saying "I don't care if you're sick. [...] Get out and vote." However, Trump made these remarks in November 2016, not during the COVID-19 pandemic.
The video was filmed during a campaign rally in Nevada on Nov. 6, 2016. It shows then-candidate Trump urging supporters to vote even if they just been given the "worst possible prognosis."
You got to get out there November 8th. I say kiddingly but I mean it: I don't care how sick you are. I don't care if you just came back from the doctor, and he gave you the worst possible prognosis, meaning it's over. You won't be around in two weeks. Doesn't matter. Hang out 'til November 8. Get out and vote. And then all we're going to say is, 'We love you and we will remember you always.'
We reported on this video when it first went viral in November 2016. And while the video is genuine, Trump was speaking to his supporters just days before the 2016 presidential election, not -- despite captions that suggest otherwise -- during the 2020 election.