How to store the data as CSV format?
Write the values to the card with commas between them.
... etc ...
How to send the data online at certain time on Arduino?
You need to make a suitable network request to whatever unknown thing it is you are sending it to. That may be a HTTP POST request, or it could be some completely different mechanism. Until you have decided where you are sending it we can't help you with the how of sending it.
As to the when, you really could do with a Real Time Clock module so you know what the time is. Then at a certain time you can run your code. Some RTC modules have an alarm that can alert you when it's time to send your code. Great for if your MCU has been placed in a sleep mode and needs waking up at the right time.
Is it better to use GSM or WiFi?
That depends if you have access to WiFi where the sensor is. If you do, then WiFi is (more often than not) cheaper. If you don't, then WiFi is impossible and GSM is the only option.