What are the drawbacks of using cookies for storing sensitive user information in PHP applications?

Storing sensitive user information in cookies can pose security risks as cookies are stored on the client-side and can be easily accessed or manipulated. To address this issue, sensitive information should be stored securely on the server-side using sessions or database storage.

// Storing sensitive information securely using sessions
session_start();
$_SESSION['user_id'] = $user_id;
$_SESSION['username'] = $username;