Is it possible to assign attributes to different roles? So let's say I have a student role. And I want assign variables to student such as attendance and grade.

Then i want a teacher role that can assign this attendance and grade to their students. 

We can pretend that there is only one teacher and there are many students.

How would this be done? I know that you can edit fields under Config->People in drupal 7, but this causes there to be the same fields for all users. 

In a similar way, is it possible to have like a "Student Page' where a student sees his/her own grade but not any one else? 

I've been trying to find similar function but it seems to not exist. 

Thanks
Yes. There many ways to go about this but the Profile2 module is one that covers the entity field data (variables) per a specified user role. 


  Designed to be the successor of the core profile module, which is
  deprecated for Drupal 7. In contrast to the deprecated module this
  module provides a new, fieldable 'profile' entity - leverage the power
  of fields!


Your your student role can be assigned to have to have a student profile which a Teacher can edit, but only a student can view. It has the additional permission View Own Profile... which should restrict students from seeing other profile pages.