If I am correctly understanding what you need, you have to provide your other columns also into the sum(). Consider the example below:
tst=sqlContext.createDataFrame([('2020-04-23',1,2,"india"),('2020-04-24',1,3,"india"),('2020-04-23',1,4,"china"),('2020-04-24',1,5,"china"),('2020-04-23',1,7,"germany"),('2020-04-24',1,9,"germany")],schema=('date','quantity','value','country'))
tst.show()
+----------+--------+-----+-------+
| date|quantity|value|country|
+----------+--------+-----+-------+
|2020-04-23| 1| 2| india|
|2020-04-24| 1| 3| india|
|2020-04-23| 1| 4| china|
|2020-04-24| 1| 5| china|
|2020-04-23| 1| 7|germany|
|2020-04-24| 1| 9|germany|
+----------+--------+-----+-------+
df_pivot=tst.groupby('country').pivot('date').sum('quantity','value').show()
df_pivot.show()
+-------+------------------------+---------------------+------------------------+---------------------+
|country|2020-04-23_sum(quantity)|2020-04-23_sum(value)|2020-04-24_sum(quantity)|2020-04-24_sum(value)|
+-------+------------------------+---------------------+------------------------+---------------------+
|germany| 1| 7| 1| 9|
| china| 1| 4| 1| 5|
| india| 1| 2| 1| 3|
+-------+------------------------+---------------------+------------------------+---------------------+
If you don't like the funny column names, then you can use the agg function to define your own suffix to the pivoted column name.
tst_res=tst.groupby('country').pivot('date').agg(F.sum('quantity').alias('sum_quantity'),F.sum('value').alias('sum_value'))
tst_res.show()
+-------+-----------------------+--------------------+-----------------------+--------------------+
|country|2020-04-23_sum_quantity|2020-04-23_sum_value|2020-04-24_sum_quantity|2020-04-24_sum_value|
+-------+-----------------------+--------------------+-----------------------+--------------------+
|germany| 1| 7| 1| 9|
| china| 1| 4| 1| 5|
| india| 1| 2| 1| 3|
+-------+-----------------------+--------------------+-----------------------+--------------------+