A timestamp is temporal information regarding an event that is recorded by the computer and then stored as a log or metadata. The timestamp is used primarily for establishing the difficulty. Without a timestamp, new nodes would not be able to determine the correct difficulty to be used for each block period as they wouldn’t know how long it took to mine those blocks. So that everyone calculates the difficulty correctly, the block timestamps are used instead of real time.