String and Integer are objects and int is primitive type. so Objects use alot more memory whereas primitive types don't.
for example if you have a primitive type as:
int i = 5;
for example in memory address 10 the value 5 will be saved and i knows address 10
but for objects as:
Integer i = new Integer(5):
the value of 5 will be saved in for example address 2 and address 10 (which is i variable) will reference to address 2 which takes more memory. When a new object is created, a composite memory block consisting of a series of consecutive blocks, one for each instance variable, is created which takes alot more memory.
String is an object, an special object but still an object . it's special because for example it doesn't need new